From a3d237f0b4d1262039a5a2bf070a164cf447ab9b Mon Sep 17 00:00:00 2001 From: Kamil Tekiela Date: Tue, 5 Dec 2023 00:04:18 +0100 Subject: [PATCH] Remove useless in_array It's always going to be either true or false. There are no other options. Signed-off-by: Kamil Tekiela --- phpstan-baseline.neon | 5 ----- src/Footer.php | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index d0fb5bf6fc..165304dd79 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -10580,11 +10580,6 @@ parameters: count: 1 path: src/Font.php - - - message: "#^Call to function in_array\\(\\) requires parameter \\#3 to be set\\.$#" - count: 1 - path: src/Footer.php - - message: "#^Construct empty\\(\\) is not allowed\\. Use more strict comparison\\.$#" count: 4 diff --git a/src/Footer.php b/src/Footer.php index 45e4f9ea03..67bf689cd5 100644 --- a/src/Footer.php +++ b/src/Footer.php @@ -141,7 +141,7 @@ class Footer $params['server'] = $GLOBALS['server']; - if (isset($_REQUEST['single_table']) && in_array($_REQUEST['single_table'], [true, false])) { + if (isset($_REQUEST['single_table'])) { $params['single_table'] = $_REQUEST['single_table']; }