From d82b03026179c2c374ef6a7c8beff7d8474a37a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maur=C3=ADcio=20Meneghini=20Fauth?= Date: Mon, 12 Oct 2020 13:38:20 -0300 Subject: [PATCH] Update PHPStan baseline MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: MaurĂ­cio Meneghini Fauth --- phpstan-baseline.neon | 29 ++++++++++++++++++++++------- 1 file changed, 22 insertions(+), 7 deletions(-) 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