From 288ed04ccc30b58373576dc3be811aee43e67034 Mon Sep 17 00:00:00 2001 From: Alexandre Alapetite Date: Fri, 31 Mar 2023 08:23:39 +0200 Subject: PHPStan level 6 for all PDO and Exception classes (#5239) * PHPStan level 6 for all PDO and Exception classes Contributes to https://github.com/FreshRSS/FreshRSS/issues/4112 * Fix type * Now also our remaining own librairies * Motivation for a few more files * A few more DAO classes * Last interface --- lib/Minz/Error.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/Minz/Error.php') diff --git a/lib/Minz/Error.php b/lib/Minz/Error.php index 3162c6f99..e23499a10 100644 --- a/lib/Minz/Error.php +++ b/lib/Minz/Error.php @@ -19,7 +19,7 @@ class Minz_Error { * > $logs['notice'] * @param bool $redirect indique s'il faut forcer la redirection (les logs ne seront pas transmis) */ - public static function error ($code = 404, $logs = array (), $redirect = true) { + public static function error(int $code = 404, array $logs = [], bool $redirect = true): void { $logs = self::processLogs ($logs); $error_filename = APP_PATH . '/Controllers/errorController.php'; @@ -52,7 +52,7 @@ class Minz_Error { * @param array|string $logs logs sorted by category (error, warning, notice) * @return array list of matching logs, without the category, according to environment preferences (production / development) */ - private static function processLogs ($logs) { + private static function processLogs($logs) { $conf = Minz_Configuration::get('system'); $env = $conf->environment; $logs_ok = array (); -- cgit v1.2.3