diff --git a/system/Log/Handlers/ChromeLoggerHandler.php b/system/Log/Handlers/ChromeLoggerHandler.php index eedea60a1558..5813f338b389 100644 --- a/system/Log/Handlers/ChromeLoggerHandler.php +++ b/system/Log/Handlers/ChromeLoggerHandler.php @@ -151,6 +151,8 @@ protected function format($object) /** * Attaches the header and the content to the passed in request object. * + * @param-out ResponseInterface $response + * * @return void */ public function sendLogs(?ResponseInterface &$response = null) diff --git a/tests/_support/Validation/TestRules.php b/tests/_support/Validation/TestRules.php index 41f765fe14a7..cb6cde9d4584 100644 --- a/tests/_support/Validation/TestRules.php +++ b/tests/_support/Validation/TestRules.php @@ -15,6 +15,9 @@ class TestRules { + /** + * @param-out string $error + */ public function customError(string $str, ?string &$error = null) { $error = 'My lovely error'; diff --git a/utils/phpstan-baseline/loader.neon b/utils/phpstan-baseline/loader.neon index 9cac99c53599..a2989fec1d0d 100644 --- a/utils/phpstan-baseline/loader.neon +++ b/utils/phpstan-baseline/loader.neon @@ -25,7 +25,6 @@ includes: - notIdentical.alwaysTrue.neon - nullCoalesce.property.neon - nullCoalesce.variable.neon - - parameterByRef.unusedType.neon - property.defaultValue.neon - property.nonObject.neon - property.notFound.neon diff --git a/utils/phpstan-baseline/parameterByRef.unusedType.neon b/utils/phpstan-baseline/parameterByRef.unusedType.neon deleted file mode 100644 index a750c89a492e..000000000000 --- a/utils/phpstan-baseline/parameterByRef.unusedType.neon +++ /dev/null @@ -1,13 +0,0 @@ -# total 2 errors - -parameters: - ignoreErrors: - - - message: '#^Method CodeIgniter\\Log\\Handlers\\ChromeLoggerHandler\:\:sendLogs\(\) never assigns null to &\$response so it can be removed from the by\-ref type\.$#' - count: 1 - path: ../../system/Log/Handlers/ChromeLoggerHandler.php - - - - message: '#^Method Tests\\Support\\Validation\\TestRules\:\:customError\(\) never assigns null to &\$error so it can be removed from the by\-ref type\.$#' - count: 1 - path: ../../tests/_support/Validation/TestRules.php