diff --git a/composer.json b/composer.json index 866f830..4f4c983 100644 --- a/composer.json +++ b/composer.json @@ -10,7 +10,7 @@ }, "require-dev": { - "phpstan/phpstan": "^1.10", + "phpstan/phpstan": "^2.2", "phpunit/phpunit": "^10.5", "phpmd/phpmd": "^2.13", "squizlabs/php_codesniffer": "^3.7" diff --git a/composer.lock b/composer.lock index 6daf634..b410bb1 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "9763e2e1e3ec8c2a41cf5370fcbcd596", + "content-hash": "760e39e8d88e97250e962ad9f43706b6", "packages": [ { "name": "justinrainbow/json-schema", @@ -1232,15 +1232,15 @@ }, { "name": "phpstan/phpstan", - "version": "1.12.34", + "version": "2.2.2", "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpstan/zipball/4dd89ca7aa30fdc6760be21550d583bcc32e8476", - "reference": "4dd89ca7aa30fdc6760be21550d583bcc32e8476", + "url": "https://api.github.com/repos/phpstan/phpstan/zipball/e5cc34d491a90e79c216d824f60fe21fd4d93bd6", + "reference": "e5cc34d491a90e79c216d824f60fe21fd4d93bd6", "shasum": "" }, "require": { - "php": "^7.2|^8.0" + "php": "^7.4|^8.0" }, "conflict": { "phpstan/phpstan-shim": "*" @@ -1259,6 +1259,17 @@ "license": [ "MIT" ], + "authors": [ + { + "name": "Ondřej Mirtes" + }, + { + "name": "Markus Staab" + }, + { + "name": "Vincent Langlet" + } + ], "description": "PHPStan - PHP Static Analysis Tool", "keywords": [ "dev", @@ -1281,7 +1292,7 @@ "type": "github" } ], - "time": "2026-07-28T10:04:39+00:00" + "time": "2026-06-05T09:00:01+00:00" }, { "name": "phpunit/php-code-coverage", diff --git a/src/Input.php b/src/Input.php index 6dedb2e..76b4476 100644 --- a/src/Input.php +++ b/src/Input.php @@ -24,8 +24,8 @@ /** * @implements ArrayAccess * @implements Iterator - * @SuppressWarnings(PHPMD.CouplingBetweenObjects) - * @SuppressWarnings(PHPMD.TooManyPublicMethods) + * @SuppressWarnings("PHPMD.CouplingBetweenObjects") + * @SuppressWarnings("PHPMD.TooManyPublicMethods") */ class Input implements ArrayAccess, Countable, Iterator { use InputValueGetter; @@ -269,7 +269,7 @@ public function with(string...$keys):Trigger { return $this->select(...$keys); } - /** @SuppressWarnings(PHPMD.UnusedLocalVariable) */ + /** @SuppressWarnings("PHPMD.UnusedLocalVariable") */ public function selectPrefix(string $prefix):Trigger { $keys = []; diff --git a/src/InputData/KeyValueIterator.php b/src/InputData/KeyValueIterator.php index 9bf6437..154d86a 100644 --- a/src/InputData/KeyValueIterator.php +++ b/src/InputData/KeyValueIterator.php @@ -33,7 +33,7 @@ protected function getIteratorDataKey():?string { if(is_array($this->parameters)) { $keys = array_keys($this->parameters); } - else if($this->parameters instanceof InputData) { + else { $keys = $this->parameters->getKeys(); }