From: Banana Date: Mon, 11 Sep 2023 09:54:00 +0000 (+0200) Subject: added a new TODO and cleaned up summoner class X-Git-Tag: 2.8.2_20230914~10 X-Git-Url: http://91.132.146.200/gitweb/?a=commitdiff_plain;h=8ef8e3c46f8a5a4f7ed92c32553d10f381972db9;p=insipid.git added a new TODO and cleaned up summoner class --- diff --git a/TODO b/TODO index 2b88b3d..0795fe3 100644 --- a/TODO +++ b/TODO @@ -1,4 +1,6 @@ TODO / Feature list ++ Replace ifset https://www.php.net/manual/en/migration70.new-features.php#migration70.new-features.null-coalesce-op + from summoner.class.php + Whole Page snapshot + view table really still needed? + theme support diff --git a/webroot/lib/summoner.class.php b/webroot/lib/summoner.class.php index 80c454c..184153d 100644 --- a/webroot/lib/summoner.class.php +++ b/webroot/lib/summoner.class.php @@ -86,7 +86,7 @@ class Summoner { // text without any whitespace and special chars // but with Punctuation other # http://www.sql-und-xml.de/unicode-database/po.html - $pattern = '/[\p{L}\p{N}\p{Po}\-]/u'; + $pattern = '/[\p{L}\p{N}\p{Po}\-_]/u'; break; case 'digit': @@ -98,7 +98,7 @@ class Summoner { case 'pageTitle': // text with whitespace and without special chars // but with Punctuation - $pattern = '/[\p{L}\p{N}\p{Po}\p{Z}\s-]/u'; + $pattern = '/[\p{L}\p{N}\p{Po}\p{Z}\s\-_]/u'; break; # strange. the \p{M} is needed.. don't know why.. @@ -391,7 +391,7 @@ class Summoner { /** * a very simple HTTP_AUTH authentication. */ - static function simpleAuth() { + static function simpleAuth(): void { if (!isset($_SERVER['PHP_AUTH_USER']) || !isset($_SERVER['PHP_AUTH_PW']) || $_SERVER['PHP_AUTH_USER'] !== FRONTEND_USERNAME || $_SERVER['PHP_AUTH_PW'] !== FRONTEND_PASSWORD ) {