From 138e73699db60b32d8f0d20a5c21fae5bc02da9d Mon Sep 17 00:00:00 2001 From: Nikolay Novikov Date: Wed, 6 Dec 2023 16:27:31 +0300 Subject: [PATCH] patch --- composer.json | 3 ++- psalm.xml | 40 +++++++++++++++++++++++++++++ src/Http/Middleware/Web/Select2.php | 5 ++-- 3 files changed, 44 insertions(+), 4 deletions(-) create mode 100644 psalm.xml diff --git a/composer.json b/composer.json index bc3877d..9dccd75 100644 --- a/composer.json +++ b/composer.json @@ -13,7 +13,8 @@ "orchestra/testbench": "^8.6", "phpstan/phpstan": "^1.10", "friendsofphp/php-cs-fixer": "^3.26", - "squizlabs/php_codesniffer": "^3.7" + "squizlabs/php_codesniffer": "^3.7", + "psalm/plugin-laravel": "^2.8" }, "autoload": { "psr-4": {"AnourValar\\LaravelAtom\\": "src/"} diff --git a/psalm.xml b/psalm.xml new file mode 100644 index 0000000..0ad415d --- /dev/null +++ b/psalm.xml @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/Http/Middleware/Web/Select2.php b/src/Http/Middleware/Web/Select2.php index 6fa15cb..0f21a30 100644 --- a/src/Http/Middleware/Web/Select2.php +++ b/src/Http/Middleware/Web/Select2.php @@ -31,17 +31,16 @@ public function handle(Request $request, Closure $next) } $response = $next($request); - $this->convertResponse($response, $request); + $this->convertResponse($response); return $response; } /** * @param \Symfony\Component\HttpFoundation\Response $response - * @param \Illuminate\Http\Request $request * @return void */ - private function convertResponse(\Symfony\Component\HttpFoundation\Response &$response, Request $request): void + private function convertResponse(\Symfony\Component\HttpFoundation\Response &$response): void { $content = $response->getOriginalContent();