diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index d46b21975e..278a9a8158 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -185,6 +185,21 @@ parameters: count: 1 path: libraries/classes/Controllers/ExportController.php + - + message: "#^If condition is always true\\.$#" + count: 1 + path: libraries/classes/Controllers/HomeController.php + + - + message: "#^Left side of \\|\\| is always true\\.$#" + count: 1 + path: libraries/classes/Controllers/HomeController.php + + - + message: "#^Right side of && is always true\\.$#" + count: 1 + path: libraries/classes/Controllers/HomeController.php + - message: "#^Negated boolean expression is always true\\.$#" count: 1 @@ -581,7 +596,7 @@ parameters: path: libraries/classes/Error.php - - message: "#^Parameter \\#1 \\$error_handler of function set_error_handler expects \\(callable\\(int, string, string, int, array\\)\\: bool\\)\\|null, array\\(\\$this\\(PhpMyAdmin\\\\ErrorHandler\\), 'handleError'\\) given\\.$#" + message: "#^Parameter \\#1 \\$callback of function set_error_handler expects \\(callable\\(int, string, string, int, array\\)\\: bool\\)\\|null, array\\(\\$this\\(PhpMyAdmin\\\\ErrorHandler\\), 'handleError'\\) given\\.$#" count: 1 path: libraries/classes/ErrorHandler.php @@ -1185,6 +1200,11 @@ parameters: count: 1 path: libraries/classes/Plugins/Import/ImportMediawiki.php + - + message: "#^Negated boolean expression is always true\\.$#" + count: 1 + path: libraries/classes/Plugins/Import/ImportMediawiki.php + - message: "#^Comparison operation \"\\>\\=\" between 0 and 0 is always true\\.$#" count: 1 @@ -1240,11 +1260,6 @@ parameters: count: 1 path: libraries/classes/Plugins/Import/ImportXml.php - - - message: "#^Parameter \\#1 \\$ns of method SimpleXMLElement\\:\\:children\\(\\) expects string, string\\|null given\\.$#" - count: 1 - path: libraries/classes/Plugins/Import/ImportXml.php - - message: "#^Offset 'name' does not exist on SimpleXMLElement\\|null\\.$#" count: 3 @@ -1956,7 +1971,7 @@ parameters: path: libraries/classes/Server/Privileges.php - - message: "#^Parameter \\#1 \\$result of method PhpMyAdmin\\\\DatabaseInterface\\:\\:freeResult\\(\\) expects object, mixed given\\.$#" + message: "#^Parameter \\#1 \\$result of method PhpMyAdmin\\\\DatabaseInterface\\:\\:freeResult\\(\\) expects object, array\\|float\\|int\\|string\\|false\\|null given\\.$#" count: 1 path: libraries/classes/Server/Privileges.php