From 00b6a3bde89a6f935ca6711a34af296c3fe5fb48 Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Mon, 1 Mar 2021 13:09:50 +0000 Subject: [PATCH 01/29] Update phpstan/phpstan requirement from ^0.12.70 to ^0.12.80 Updates the requirements on [phpstan/phpstan](https://github.com/phpstan/phpstan) to permit the latest version. - [Release notes](https://github.com/phpstan/phpstan/releases) - [Commits](https://github.com/phpstan/phpstan/compare/0.12.70...0.12.80) Signed-off-by: dependabot-preview[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index e0ba2de67..eaf78f889 100644 --- a/composer.json +++ b/composer.json @@ -62,7 +62,7 @@ "nyholm/psr7": "^1.3", "nyholm/psr7-server": "^1.0.1", "phpspec/prophecy": "^1.12", - "phpstan/phpstan": "^0.12.70", + "phpstan/phpstan": "^0.12.80", "phpunit/phpunit": "^8.5.13 || ^9.3.8", "slim/http": "^1.2", "slim/psr7": "^1.3", From df60b8906233b0708d1025fd59a6769b8dc8833a Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Tue, 2 Mar 2021 01:17:12 +0000 Subject: [PATCH 02/29] Update nyholm/psr7 requirement from ^1.3 to ^1.4 Updates the requirements on [nyholm/psr7](https://github.com/Nyholm/psr7) to permit the latest version. - [Release notes](https://github.com/Nyholm/psr7/releases) - [Changelog](https://github.com/Nyholm/psr7/blob/master/CHANGELOG.md) - [Commits](https://github.com/Nyholm/psr7/compare/1.3.0...1.4.0) Signed-off-by: dependabot-preview[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index eaf78f889..22d749d3d 100644 --- a/composer.json +++ b/composer.json @@ -59,7 +59,7 @@ "guzzlehttp/psr7": "^1.7", "http-interop/http-factory-guzzle": "^1.0", "laminas/laminas-diactoros": "^2.4", - "nyholm/psr7": "^1.3", + "nyholm/psr7": "^1.4", "nyholm/psr7-server": "^1.0.1", "phpspec/prophecy": "^1.12", "phpstan/phpstan": "^0.12.80", From 6c71e5d539d16865a9cefbcd5bcbc459ac8c5014 Mon Sep 17 00:00:00 2001 From: Ayesh Karunaratne Date: Sat, 6 Mar 2021 19:21:22 +0700 Subject: [PATCH 03/29] Allow ^1.0 || ^2.0 in psr/container --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 22d749d3d..56c82fa9c 100644 --- a/composer.json +++ b/composer.json @@ -46,7 +46,7 @@ "php": "^7.2 || ^8.0", "ext-json": "*", "nikic/fast-route": "^1.3", - "psr/container": "^1.0", + "psr/container": "^1.0 || ^2.0", "psr/http-factory": "^1.0", "psr/http-message": "^1.0", "psr/http-server-handler": "^1.0", From 78008b36b39318d8df665d57d155f282c337392b Mon Sep 17 00:00:00 2001 From: Ivan Dudarev Date: Sat, 17 Apr 2021 22:14:39 +0700 Subject: [PATCH 04/29] Array routes --- Slim/CallableResolver.php | 20 +++++++++++++++++ tests/CallableResolverTest.php | 40 +++++++++++++++++++++++++++++++--- 2 files changed, 57 insertions(+), 3 deletions(-) diff --git a/Slim/CallableResolver.php b/Slim/CallableResolver.php index f2c5fe4cd..407724b5d 100644 --- a/Slim/CallableResolver.php +++ b/Slim/CallableResolver.php @@ -51,6 +51,7 @@ public function __construct(?ContainerInterface $container = null) */ public function resolve($toResolve): callable { + $toResolve = $this->prepareToResolve($toResolve); if (is_callable($toResolve)) { return $this->bindToContainer($toResolve); } @@ -90,6 +91,7 @@ public function resolveMiddleware($toResolve): callable */ private function resolveByPredicate($toResolve, callable $predicate, string $defaultMethod): callable { + $toResolve = $this->prepareToResolve($toResolve); if (is_callable($toResolve)) { return $this->bindToContainer($toResolve); } @@ -187,4 +189,22 @@ private function bindToContainer(callable $callable): callable } return $callable; } + + /** + * @param string|callable $toResolve + * @return string|callable + */ + private function prepareToResolve($toResolve) + { + if (!is_array($toResolve)) { + return $toResolve; + } + $array = $toResolve; + $class = array_shift($array); + $method = array_shift($array); + if (is_string($class) && is_string($method)) { + return $class . ':' . $method; + } + return $toResolve; + } } diff --git a/tests/CallableResolverTest.php b/tests/CallableResolverTest.php index 727164c48..8d739154b 100644 --- a/tests/CallableResolverTest.php +++ b/tests/CallableResolverTest.php @@ -133,6 +133,23 @@ public function testSlimCallable() $this->assertEquals(3, CallableTest::$CalledCount); } + public function testSlimCallableAsArray() + { + $resolver = new CallableResolver(); // No container injected + $callable = $resolver->resolve([CallableTest::class, 'toCall']); + $callableRoute = $resolver->resolveRoute([CallableTest::class, 'toCall']); + $callableMiddleware = $resolver->resolveMiddleware([CallableTest::class, 'toCall']); + + $callable(); + $this->assertEquals(1, CallableTest::$CalledCount); + + $callableRoute(); + $this->assertEquals(2, CallableTest::$CalledCount); + + $callableMiddleware(); + $this->assertEquals(3, CallableTest::$CalledCount); + } + public function testSlimCallableContainer() { /** @var ContainerInterface $container */ @@ -150,6 +167,23 @@ public function testSlimCallableContainer() $this->assertEquals($container, CallableTest::$CalledContainer); } + public function testSlimCallableAsArrayContainer() + { + /** @var ContainerInterface $container */ + $container = $this->containerProphecy->reveal(); + $resolver = new CallableResolver($container); + $resolver->resolve([CallableTest::class, 'toCall']); + $this->assertEquals($container, CallableTest::$CalledContainer); + + CallableTest::$CalledContainer = null; + $resolver->resolveRoute([CallableTest::class, 'toCall']); + $this->assertEquals($container, CallableTest::$CalledContainer); + + CallableTest::$CalledContainer = null; + $resolver->resolveMiddleware([CallableTest::class ,'toCall']); + $this->assertEquals($container, CallableTest::$CalledContainer); + } + public function testContainer() { $this->containerProphecy->has('callable_service')->willReturn(true); @@ -474,7 +508,7 @@ public function testMiddlewareClassNotFoundThrowException() public function testCallableClassNotFoundThrowException() { $this->expectException(RuntimeException::class); - $this->expectExceptionMessage('is not resolvable'); + $this->expectExceptionMessage('Callable Unknown does not exist'); /** @var ContainerInterface $container */ $container = $this->containerProphecy->reveal(); @@ -485,7 +519,7 @@ public function testCallableClassNotFoundThrowException() public function testRouteCallableClassNotFoundThrowException() { $this->expectException(RuntimeException::class); - $this->expectExceptionMessage('is not resolvable'); + $this->expectExceptionMessage('Callable Unknown does not exist'); /** @var ContainerInterface $container */ $container = $this->containerProphecy->reveal(); @@ -496,7 +530,7 @@ public function testRouteCallableClassNotFoundThrowException() public function testMiddlewareCallableClassNotFoundThrowException() { $this->expectException(RuntimeException::class); - $this->expectExceptionMessage('is not resolvable'); + $this->expectExceptionMessage('Callable Unknown does not exist'); /** @var ContainerInterface $container */ $container = $this->containerProphecy->reveal(); From 985052c2eab3bb20ce57280cc722c57b54ed0060 Mon Sep 17 00:00:00 2001 From: Ivan Dudarev Date: Sun, 18 Apr 2021 15:36:34 +0700 Subject: [PATCH 05/29] Rename variable --- Slim/CallableResolver.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Slim/CallableResolver.php b/Slim/CallableResolver.php index 407724b5d..a622dcbee 100644 --- a/Slim/CallableResolver.php +++ b/Slim/CallableResolver.php @@ -199,9 +199,9 @@ private function prepareToResolve($toResolve) if (!is_array($toResolve)) { return $toResolve; } - $array = $toResolve; - $class = array_shift($array); - $method = array_shift($array); + $candidate = $toResolve; + $class = array_shift($candidate); + $method = array_shift($candidate); if (is_string($class) && is_string($method)) { return $class . ':' . $method; } From 2b8774e9011a1afbf7992984a31d7f234989ab6f Mon Sep 17 00:00:00 2001 From: Ivan Dudarev Date: Sun, 18 Apr 2021 15:43:06 +0700 Subject: [PATCH 06/29] Add method name to error message --- Slim/CallableResolver.php | 3 +++ tests/CallableResolverTest.php | 12 ++++++------ 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/Slim/CallableResolver.php b/Slim/CallableResolver.php index a622dcbee..c1c351276 100644 --- a/Slim/CallableResolver.php +++ b/Slim/CallableResolver.php @@ -146,6 +146,9 @@ private function resolveSlimNotation(string $toResolve): array $instance = $this->container->get($class); } else { if (!class_exists($class)) { + if ($method) { + $class .= '::' . $method . '()'; + } throw new RuntimeException(sprintf('Callable %s does not exist', $class)); } $instance = new $class($this->container); diff --git a/tests/CallableResolverTest.php b/tests/CallableResolverTest.php index 8d739154b..27e0823a5 100644 --- a/tests/CallableResolverTest.php +++ b/tests/CallableResolverTest.php @@ -475,7 +475,7 @@ public function testMiddlewareFunctionNotFoundThrowException() public function testClassNotFoundThrowException() { $this->expectException(RuntimeException::class); - $this->expectExceptionMessage('Callable Unknown does not exist'); + $this->expectExceptionMessage('Callable Unknown::notFound() does not exist'); /** @var ContainerInterface $container */ $container = $this->containerProphecy->reveal(); @@ -486,7 +486,7 @@ public function testClassNotFoundThrowException() public function testRouteClassNotFoundThrowException() { $this->expectException(RuntimeException::class); - $this->expectExceptionMessage('Callable Unknown does not exist'); + $this->expectExceptionMessage('Callable Unknown::notFound() does not exist'); /** @var ContainerInterface $container */ $container = $this->containerProphecy->reveal(); @@ -497,7 +497,7 @@ public function testRouteClassNotFoundThrowException() public function testMiddlewareClassNotFoundThrowException() { $this->expectException(RuntimeException::class); - $this->expectExceptionMessage('Callable Unknown does not exist'); + $this->expectExceptionMessage('Callable Unknown::notFound() does not exist'); /** @var ContainerInterface $container */ $container = $this->containerProphecy->reveal(); @@ -508,7 +508,7 @@ public function testMiddlewareClassNotFoundThrowException() public function testCallableClassNotFoundThrowException() { $this->expectException(RuntimeException::class); - $this->expectExceptionMessage('Callable Unknown does not exist'); + $this->expectExceptionMessage('Callable Unknown::notFound() does not exist'); /** @var ContainerInterface $container */ $container = $this->containerProphecy->reveal(); @@ -519,7 +519,7 @@ public function testCallableClassNotFoundThrowException() public function testRouteCallableClassNotFoundThrowException() { $this->expectException(RuntimeException::class); - $this->expectExceptionMessage('Callable Unknown does not exist'); + $this->expectExceptionMessage('Callable Unknown::notFound() does not exist'); /** @var ContainerInterface $container */ $container = $this->containerProphecy->reveal(); @@ -530,7 +530,7 @@ public function testRouteCallableClassNotFoundThrowException() public function testMiddlewareCallableClassNotFoundThrowException() { $this->expectException(RuntimeException::class); - $this->expectExceptionMessage('Callable Unknown does not exist'); + $this->expectExceptionMessage('Callable Unknown::notFound() does not exist'); /** @var ContainerInterface $container */ $container = $this->containerProphecy->reveal(); From eff5987cb4aa7271d19f07206df3e66afcb99c3a Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Wed, 28 Apr 2021 16:46:38 +0000 Subject: [PATCH 07/29] Upgrade to GitHub-native Dependabot --- .github/dependabot.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 000000000..cf7584931 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,12 @@ +version: 2 +updates: +- package-ecosystem: composer + directory: "/" + schedule: + interval: monthly + open-pull-requests-limit: 10 + versioning-strategy: increase + ignore: + - dependency-name: phpunit/phpunit + versions: + - 8.5.14 From b73334c65cfa190d669d7051825a16ee84b1cca2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 29 Apr 2021 03:36:59 +0000 Subject: [PATCH 08/29] Update phpstan/phpstan requirement from ^0.12.80 to ^0.12.85 Updates the requirements on [phpstan/phpstan](https://github.com/phpstan/phpstan) to permit the latest version. - [Release notes](https://github.com/phpstan/phpstan/releases) - [Commits](https://github.com/phpstan/phpstan/compare/0.12.80...0.12.85) Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 56c82fa9c..ebde4b9a5 100644 --- a/composer.json +++ b/composer.json @@ -62,7 +62,7 @@ "nyholm/psr7": "^1.4", "nyholm/psr7-server": "^1.0.1", "phpspec/prophecy": "^1.12", - "phpstan/phpstan": "^0.12.80", + "phpstan/phpstan": "^0.12.85", "phpunit/phpunit": "^8.5.13 || ^9.3.8", "slim/http": "^1.2", "slim/psr7": "^1.3", From 1956c793c6268f67272b88975cb9a82b143ea059 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 29 Apr 2021 03:41:24 +0000 Subject: [PATCH 09/29] Update phpspec/prophecy requirement from ^1.12 to ^1.13 Updates the requirements on [phpspec/prophecy](https://github.com/phpspec/prophecy) to permit the latest version. - [Release notes](https://github.com/phpspec/prophecy/releases) - [Changelog](https://github.com/phpspec/prophecy/blob/master/CHANGES.md) - [Commits](https://github.com/phpspec/prophecy/compare/1.12.0...1.13.0) Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index ebde4b9a5..808da94a4 100644 --- a/composer.json +++ b/composer.json @@ -61,7 +61,7 @@ "laminas/laminas-diactoros": "^2.4", "nyholm/psr7": "^1.4", "nyholm/psr7-server": "^1.0.1", - "phpspec/prophecy": "^1.12", + "phpspec/prophecy": "^1.13", "phpstan/phpstan": "^0.12.85", "phpunit/phpunit": "^8.5.13 || ^9.3.8", "slim/http": "^1.2", From 25440832b3f600bccc23c98fbc0fef7899d91c11 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 29 Apr 2021 03:41:24 +0000 Subject: [PATCH 10/29] Update squizlabs/php_codesniffer requirement from ^3.5 to ^3.6 Updates the requirements on [squizlabs/php_codesniffer](https://github.com/squizlabs/PHP_CodeSniffer) to permit the latest version. - [Release notes](https://github.com/squizlabs/PHP_CodeSniffer/releases) - [Commits](https://github.com/squizlabs/PHP_CodeSniffer/compare/3.5.0...3.6.0) Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index ebde4b9a5..1b1c03a35 100644 --- a/composer.json +++ b/composer.json @@ -66,7 +66,7 @@ "phpunit/phpunit": "^8.5.13 || ^9.3.8", "slim/http": "^1.2", "slim/psr7": "^1.3", - "squizlabs/php_codesniffer": "^3.5", + "squizlabs/php_codesniffer": "^3.6", "weirdan/prophecy-shim": "^1.0 || ^2.0.2" }, "autoload": { From 407edb0dae1f5aef1b2c163eaac5e9431e112e7a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 29 Apr 2021 03:41:28 +0000 Subject: [PATCH 11/29] Update guzzlehttp/psr7 requirement from ^1.7 to ^1.8 Updates the requirements on [guzzlehttp/psr7](https://github.com/guzzle/psr7) to permit the latest version. - [Release notes](https://github.com/guzzle/psr7/releases) - [Changelog](https://github.com/guzzle/psr7/blob/1.8.2/CHANGELOG.md) - [Commits](https://github.com/guzzle/psr7/compare/1.7.0...1.8.2) Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index ebde4b9a5..c99e42d2f 100644 --- a/composer.json +++ b/composer.json @@ -56,7 +56,7 @@ "require-dev": { "ext-simplexml": "*", "adriansuter/php-autoload-override": "^1.2", - "guzzlehttp/psr7": "^1.7", + "guzzlehttp/psr7": "^1.8", "http-interop/http-factory-guzzle": "^1.0", "laminas/laminas-diactoros": "^2.4", "nyholm/psr7": "^1.4", From 9b10b4d1dc8c5c9d389ee68c7d90ea8e8aefdaf1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre=20B=C3=A9rub=C3=A9?= Date: Wed, 19 May 2021 18:37:04 -0600 Subject: [PATCH 12/29] update changelog --- CHANGELOG.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1f5e823dc..46dc21bf8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,22 @@ # Changelog +# 4.8.0 - 2021-05-19 +- [3034: Fix phpunit dependency version](https://github.com/slimphp/Slim/pull/3034) thanks to @l0gicgate +- [3037: Replace Travis by GitHub Actions](https://github.com/slimphp/Slim/pull/3037) thanks to @t0mmy742 +- [3043: Cover App creation from AppFactory with empty Container](https://github.com/slimphp/Slim/pull/3043) thanks to @t0mmy742 +- [3045: Update phpstan/phpstan requirement from ^0.12.58 to ^0.12.64](https://github.com/slimphp/Slim/pull/3045) thanks to @dependabot-preview[bot] +- [3047: documentation: min php 7.2 required](https://github.com/slimphp/Slim/pull/3047) thanks to @Rotzbua +- [3054: Update phpstan/phpstan requirement from ^0.12.64 to ^0.12.70](https://github.com/slimphp/Slim/pull/3054) thanks to @dependabot-preview[bot] +- [3056: Fix docblock in ErrorMiddleware](https://github.com/slimphp/Slim/pull/3056) thanks to @piotr-cz +- [3060: Update phpstan/phpstan requirement from ^0.12.70 to ^0.12.80](https://github.com/slimphp/Slim/pull/3060) thanks to @dependabot-preview[bot] +- [3061: Update nyholm/psr7 requirement from ^1.3 to ^1.4](https://github.com/slimphp/Slim/pull/3061) thanks to @dependabot-preview[bot] +- [3063: Allow ^1.0 || ^2.0 in psr/container](https://github.com/slimphp/Slim/pull/3063) thanks to @Ayesh +- [3069: Classname/Method Callable Arrays](https://github.com/slimphp/Slim/pull/3069) thanks to @ddrv +- [3078: Update squizlabs/php_codesniffer requirement from ^3.5 to ^3.6](https://github.com/slimphp/Slim/pull/3078) thanks to @dependabot[bot] +- [3079: Update phpspec/prophecy requirement from ^1.12 to ^1.13](https://github.com/slimphp/Slim/pull/3079) thanks to @dependabot[bot] +- [3080: Update guzzlehttp/psr7 requirement from ^1.7 to ^1.8](https://github.com/slimphp/Slim/pull/3080) thanks to @dependabot[bot] +- [3082: Update phpstan/phpstan requirement from ^0.12.80 to ^0.12.85](https://github.com/slimphp/Slim/pull/3082) thanks to @dependabot[bot] + # 4.7.0 - 2020-11-30 ### Fixed From 0719254c824b564c2681fb6e1aa48d331904c445 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 1 Jun 2021 05:50:19 +0000 Subject: [PATCH 13/29] Update nyholm/psr7-server requirement from ^1.0.1 to ^1.0.2 Updates the requirements on [nyholm/psr7-server](https://github.com/Nyholm/psr7-server) to permit the latest version. - [Release notes](https://github.com/Nyholm/psr7-server/releases) - [Changelog](https://github.com/Nyholm/psr7-server/blob/master/CHANGELOG.md) - [Commits](https://github.com/Nyholm/psr7-server/compare/1.0.1...1.0.2) Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 037fc7064..c56d60c12 100644 --- a/composer.json +++ b/composer.json @@ -60,7 +60,7 @@ "http-interop/http-factory-guzzle": "^1.0", "laminas/laminas-diactoros": "^2.4", "nyholm/psr7": "^1.4", - "nyholm/psr7-server": "^1.0.1", + "nyholm/psr7-server": "^1.0.2", "phpspec/prophecy": "^1.13", "phpstan/phpstan": "^0.12.85", "phpunit/phpunit": "^8.5.13 || ^9.3.8", From c8934c35d9d98b1a1df9f99ee69b77a59e0aa820 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre=20B=C3=A9rub=C3=A9?= Date: Tue, 29 Jun 2021 13:41:06 -0600 Subject: [PATCH 14/29] Update app version to 4.8.1 --- Slim/App.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Slim/App.php b/Slim/App.php index b97a6969b..8799188ba 100644 --- a/Slim/App.php +++ b/Slim/App.php @@ -38,7 +38,7 @@ class App extends RouteCollectorProxy implements RequestHandlerInterface * * @var string */ - public const VERSION = '4.7.0'; + public const VERSION = '4.8.1'; /** * @var RouteResolverInterface From 5032aa02f97f8da4f3171ec7e28dd96fd0a889d8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 1 Jul 2021 03:01:53 +0000 Subject: [PATCH 15/29] Update phpstan/phpstan requirement from ^0.12.85 to ^0.12.90 Updates the requirements on [phpstan/phpstan](https://github.com/phpstan/phpstan) to permit the latest version. - [Release notes](https://github.com/phpstan/phpstan/releases) - [Commits](https://github.com/phpstan/phpstan/compare/0.12.85...0.12.90) --- updated-dependencies: - dependency-name: phpstan/phpstan dependency-type: direct:development ... Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 037fc7064..95e7e39d7 100644 --- a/composer.json +++ b/composer.json @@ -62,7 +62,7 @@ "nyholm/psr7": "^1.4", "nyholm/psr7-server": "^1.0.1", "phpspec/prophecy": "^1.13", - "phpstan/phpstan": "^0.12.85", + "phpstan/phpstan": "^0.12.90", "phpunit/phpunit": "^8.5.13 || ^9.3.8", "slim/http": "^1.2", "slim/psr7": "^1.3", From 280e175e5a5c0ae117c9782029118fcd38e90bb7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 3 Jul 2021 19:15:21 +0000 Subject: [PATCH 16/29] Update slim/psr7 requirement from ^1.3 to ^1.4 Updates the requirements on [slim/psr7](https://github.com/slimphp/Slim-Psr7) to permit the latest version. - [Release notes](https://github.com/slimphp/Slim-Psr7/releases) - [Commits](https://github.com/slimphp/Slim-Psr7/compare/1.3.0...1.4) Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 853019d6f..45827f849 100644 --- a/composer.json +++ b/composer.json @@ -65,7 +65,7 @@ "phpstan/phpstan": "^0.12.90", "phpunit/phpunit": "^8.5.13 || ^9.3.8", "slim/http": "^1.2", - "slim/psr7": "^1.3", + "slim/psr7": "^1.4", "squizlabs/php_codesniffer": "^3.6", "weirdan/prophecy-shim": "^1.0 || ^2.0.2" }, From fc484b4866907b60b9b73f5473066654170b4526 Mon Sep 17 00:00:00 2001 From: Thomas LE BERRE <29512640+t0mmy742@users.noreply.github.com> Date: Mon, 2 Aug 2021 20:56:09 +0200 Subject: [PATCH 17/29] Allow new version (^2.0 and ^3.0) of psr/log --- .github/dependabot.yml | 2 +- Slim/Logger.php | 11 ++++++----- composer.json | 14 +++++++------- 3 files changed, 14 insertions(+), 13 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index cf7584931..e4f63e21f 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -9,4 +9,4 @@ updates: ignore: - dependency-name: phpunit/phpunit versions: - - 8.5.14 + - "8.5.*" diff --git a/Slim/Logger.php b/Slim/Logger.php index e6abc9891..c990f19b7 100644 --- a/Slim/Logger.php +++ b/Slim/Logger.php @@ -12,20 +12,21 @@ use Psr\Log\AbstractLogger; use Psr\Log\InvalidArgumentException; +use Stringable; class Logger extends AbstractLogger { /** - * @param mixed $level - * @param string $message - * @param array $context + * @param mixed $level + * @param string|Stringable $message + * @param array $context * * @return void * * @throws InvalidArgumentException */ - public function log($level, $message, array $context = []) + public function log($level, $message, array $context = []): void { - error_log($message); + error_log((string) $message); } } diff --git a/composer.json b/composer.json index 45827f849..49304ca56 100644 --- a/composer.json +++ b/composer.json @@ -51,23 +51,23 @@ "psr/http-message": "^1.0", "psr/http-server-handler": "^1.0", "psr/http-server-middleware": "^1.0", - "psr/log": "^1.1" + "psr/log": "^1.1 || ^2.0 || ^3.0" }, "require-dev": { "ext-simplexml": "*", "adriansuter/php-autoload-override": "^1.2", - "guzzlehttp/psr7": "^1.8", - "http-interop/http-factory-guzzle": "^1.0", + "guzzlehttp/psr7": "^2.0", + "http-interop/http-factory-guzzle": "^1.1", "laminas/laminas-diactoros": "^2.4", "nyholm/psr7": "^1.4", - "nyholm/psr7-server": "^1.0.2", + "nyholm/psr7-server": "^1.0", "phpspec/prophecy": "^1.13", - "phpstan/phpstan": "^0.12.90", - "phpunit/phpunit": "^8.5.13 || ^9.3.8", + "phpstan/phpstan": "^0.12.94", + "phpunit/phpunit": "^8.5 || ^9.5", "slim/http": "^1.2", "slim/psr7": "^1.4", "squizlabs/php_codesniffer": "^3.6", - "weirdan/prophecy-shim": "^1.0 || ^2.0.2" + "weirdan/prophecy-shim": "^1.0 || ^2.0" }, "autoload": { "psr-4": { From c6c3174a1572fa45099c37a379253f8c8c6bb2b9 Mon Sep 17 00:00:00 2001 From: Thomas LE BERRE <29512640+t0mmy742@users.noreply.github.com> Date: Mon, 2 Aug 2021 21:06:01 +0200 Subject: [PATCH 18/29] Install php-coveralls/php-coveralls with --with-all-dependencies (-W) option to let it downgrade psr/log --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 4fe461afc..5f1fabbf9 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -47,5 +47,5 @@ jobs: env: COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | - composer require php-coveralls/php-coveralls -n + composer require php-coveralls/php-coveralls -n -W vendor/bin/php-coveralls --coverage_clover=clover.xml -v From 249b0b3f4ca5717bede8f11be297dfca58cbda0c Mon Sep 17 00:00:00 2001 From: Thomas LE BERRE <29512640+t0mmy742@users.noreply.github.com> Date: Mon, 2 Aug 2021 21:11:08 +0200 Subject: [PATCH 19/29] Add missing 'use function' --- Slim/Logger.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Slim/Logger.php b/Slim/Logger.php index c990f19b7..304ccb6bd 100644 --- a/Slim/Logger.php +++ b/Slim/Logger.php @@ -14,6 +14,8 @@ use Psr\Log\InvalidArgumentException; use Stringable; +use function error_log; + class Logger extends AbstractLogger { /** From dce3ed832f0c1cea62cf2ab02a8d58cfbd53fa5e Mon Sep 17 00:00:00 2001 From: Thomas LE BERRE <29512640+t0mmy742@users.noreply.github.com> Date: Tue, 3 Aug 2021 00:12:43 +0200 Subject: [PATCH 20/29] Update dependencies when dropping PHP 7.2 --- .github/dependabot.yml | 4 ---- .github/workflows/tests.yml | 4 ++-- composer.json | 14 +++++++------- phpstan.neon.dist | 5 +++-- phpunit.xml.dist | 34 +++++++++++----------------------- 5 files changed, 23 insertions(+), 38 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index e4f63e21f..9e4c2eee0 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -6,7 +6,3 @@ updates: interval: monthly open-pull-requests-limit: 10 versioning-strategy: increase - ignore: - - dependency-name: phpunit/phpunit - versions: - - "8.5.*" diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 5f1fabbf9..63bf99355 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -10,7 +10,7 @@ jobs: strategy: fail-fast: false matrix: - php: [7.2, 7.3, 7.4, 8.0] + php: [7.3, 7.4, 8.0] experimental: [false] include: - php: 8.0 @@ -37,7 +37,7 @@ jobs: - name: Static analysis if: matrix.analysis - run: vendor/bin/phpstan analyse Slim + run: vendor/bin/phpstan - name: Tests run: vendor/bin/phpunit --coverage-clover clover.xml diff --git a/composer.json b/composer.json index 49304ca56..80cabde88 100644 --- a/composer.json +++ b/composer.json @@ -43,7 +43,7 @@ "wiki": "https://github.com/slimphp/Slim/wiki" }, "require": { - "php": "^7.2 || ^8.0", + "php": "^7.3 || ^8.0", "ext-json": "*", "nikic/fast-route": "^1.3", "psr/container": "^1.0 || ^2.0", @@ -57,17 +57,17 @@ "ext-simplexml": "*", "adriansuter/php-autoload-override": "^1.2", "guzzlehttp/psr7": "^2.0", - "http-interop/http-factory-guzzle": "^1.1", - "laminas/laminas-diactoros": "^2.4", + "http-interop/http-factory-guzzle": "^1.2", + "laminas/laminas-diactoros": "^2.6", "nyholm/psr7": "^1.4", "nyholm/psr7-server": "^1.0", "phpspec/prophecy": "^1.13", + "phpspec/prophecy-phpunit": "^2.0", "phpstan/phpstan": "^0.12.94", - "phpunit/phpunit": "^8.5 || ^9.5", + "phpunit/phpunit": "^9.5", "slim/http": "^1.2", "slim/psr7": "^1.4", - "squizlabs/php_codesniffer": "^3.6", - "weirdan/prophecy-shim": "^1.0 || ^2.0" + "squizlabs/php_codesniffer": "^3.6" }, "autoload": { "psr-4": { @@ -87,7 +87,7 @@ ], "phpunit": "phpunit", "phpcs": "phpcs", - "phpstan": "phpstan analyse Slim --memory-limit=-1" + "phpstan": "phpstan --memory-limit=-1" }, "suggest": { "ext-simplexml": "Needed to support XML format in BodyParsingMiddleware", diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 036e5a516..d81898e60 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -1,3 +1,4 @@ parameters: - level: max - inferPrivatePropertyTypeFromConstructor: true + level: max + paths: + - Slim diff --git a/phpunit.xml.dist b/phpunit.xml.dist index ca2714d44..2bbfaf422 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -1,36 +1,24 @@ - ./tests/ + tests - - - ./Slim/ - - - - - + + + + Slim + + + + + From 95bc1753c5c8911fda441280ec80fb6e20e18e7b Mon Sep 17 00:00:00 2001 From: Thomas LE BERRE <29512640+t0mmy742@users.noreply.github.com> Date: Tue, 3 Aug 2021 00:21:15 +0200 Subject: [PATCH 21/29] Remove PHPUnit 7.5 polyfill --- tests/MigratePhpUnitDeprecations.php | 27 --------------------------- tests/TestCase.php | 1 - 2 files changed, 28 deletions(-) delete mode 100644 tests/MigratePhpUnitDeprecations.php diff --git a/tests/MigratePhpUnitDeprecations.php b/tests/MigratePhpUnitDeprecations.php deleted file mode 100644 index 100878ff7..000000000 --- a/tests/MigratePhpUnitDeprecations.php +++ /dev/null @@ -1,27 +0,0 @@ - Date: Tue, 3 Aug 2021 00:29:13 +0200 Subject: [PATCH 22/29] Cleanup old files --- tests/Assets/PhpFunctionOverrides.php | 58 -------------------- tests/Assets/PhpRoutingFunctionOverrides.php | 41 -------------- tests/bootstrap.php | 3 - 3 files changed, 102 deletions(-) delete mode 100644 tests/Assets/PhpFunctionOverrides.php delete mode 100644 tests/Assets/PhpRoutingFunctionOverrides.php diff --git a/tests/Assets/PhpFunctionOverrides.php b/tests/Assets/PhpFunctionOverrides.php deleted file mode 100644 index c13b8cb69..000000000 --- a/tests/Assets/PhpFunctionOverrides.php +++ /dev/null @@ -1,58 +0,0 @@ - $string, - 'replace' => $replace, - 'status_code' => $statusCode, - ] - ); -} - -/** - * Allows the mocking of invalid HTTP states. - * - * @return int - */ -function connection_status() -{ - if (isset($GLOBALS['connection_status_return'])) { - return $GLOBALS['connection_status_return']; - } - - return \connection_status(); -} diff --git a/tests/Assets/PhpRoutingFunctionOverrides.php b/tests/Assets/PhpRoutingFunctionOverrides.php deleted file mode 100644 index 40f441933..000000000 --- a/tests/Assets/PhpRoutingFunctionOverrides.php +++ /dev/null @@ -1,41 +0,0 @@ - [ 'connection_status' => function (): int { From 45607c9d110c5290618c8b6d478fc2fc724a7f53 Mon Sep 17 00:00:00 2001 From: Thomas LE BERRE <29512640+t0mmy742@users.noreply.github.com> Date: Fri, 13 Aug 2021 19:43:16 +0200 Subject: [PATCH 23/29] Use PSR-17 factory from Guzzle/psr7 2.0 to replace http-interop/http-factory-guzzle --- Slim/Factory/Psr17/GuzzlePsr17Factory.php | 4 ++-- composer.json | 1 - tests/Factory/AppFactoryTest.php | 4 ++-- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/Slim/Factory/Psr17/GuzzlePsr17Factory.php b/Slim/Factory/Psr17/GuzzlePsr17Factory.php index 8ac770291..702d537d1 100644 --- a/Slim/Factory/Psr17/GuzzlePsr17Factory.php +++ b/Slim/Factory/Psr17/GuzzlePsr17Factory.php @@ -12,8 +12,8 @@ class GuzzlePsr17Factory extends Psr17Factory { - protected static $responseFactoryClass = 'Http\Factory\Guzzle\ResponseFactory'; - protected static $streamFactoryClass = 'Http\Factory\Guzzle\StreamFactory'; + protected static $responseFactoryClass = 'GuzzleHttp\Psr7\HttpFactory'; + protected static $streamFactoryClass = 'GuzzleHttp\Psr7\HttpFactory'; protected static $serverRequestCreatorClass = 'GuzzleHttp\Psr7\ServerRequest'; protected static $serverRequestCreatorMethod = 'fromGlobals'; } diff --git a/composer.json b/composer.json index 80cabde88..22d42bf0c 100644 --- a/composer.json +++ b/composer.json @@ -57,7 +57,6 @@ "ext-simplexml": "*", "adriansuter/php-autoload-override": "^1.2", "guzzlehttp/psr7": "^2.0", - "http-interop/http-factory-guzzle": "^1.2", "laminas/laminas-diactoros": "^2.6", "nyholm/psr7": "^1.4", "nyholm/psr7-server": "^1.0", diff --git a/tests/Factory/AppFactoryTest.php b/tests/Factory/AppFactoryTest.php index ecfae162e..67f2112af 100644 --- a/tests/Factory/AppFactoryTest.php +++ b/tests/Factory/AppFactoryTest.php @@ -10,7 +10,7 @@ namespace Slim\Tests\Factory; -use Http\Factory\Guzzle\ResponseFactory as GuzzleResponseFactory; +use GuzzleHttp\Psr7\HttpFactory; use Laminas\Diactoros\ResponseFactory as LaminasDiactorosResponseFactory; use Nyholm\Psr7\Factory\Psr17Factory; use Psr\Container\ContainerInterface; @@ -46,7 +46,7 @@ public function provideImplementations() return [ [SlimPsr17Factory::class, SlimResponseFactory::class], [NyholmPsr17Factory::class, Psr17Factory::class], - [GuzzlePsr17Factory::class, GuzzleResponseFactory::class], + [GuzzlePsr17Factory::class, HttpFactory::class], [LaminasDiactorosPsr17Factory::class, LaminasDiactorosResponseFactory::class], [ZendDiactorosPsr17Factory::class, ZendDiactorosResponseFactory::class], ]; From 7d79af5684a52bb1f7e4ab732c821cb4f6fcc0d8 Mon Sep 17 00:00:00 2001 From: Thomas LE BERRE <29512640+t0mmy742@users.noreply.github.com> Date: Sun, 22 Aug 2021 14:03:30 +0200 Subject: [PATCH 24/29] Update README file --- README.md | 8 ++++---- composer.json | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index ad1177db6..59ff1d857 100644 --- a/README.md +++ b/README.md @@ -12,17 +12,17 @@ Slim is a PHP micro-framework that helps you quickly write simple yet powerful w It's recommended that you use [Composer](https://getcomposer.org/) to install Slim. ```bash -$ composer require slim/slim:^4.0 +$ composer require slim/slim ``` -This will install Slim and all required dependencies. Slim requires PHP 7.2 or newer. +This will install Slim and all required dependencies. Slim requires PHP 7.3 or newer. ## Choose a PSR-7 Implementation & ServerRequest Creator Before you can get up and running with Slim you will need to choose a PSR-7 implementation that best fits your application. A few notable ones: - [Slim-Psr7](https://github.com/slimphp/Slim-Psr7) - This is the Slim Framework PSR-7 implementation - [Nyholm/psr7](https://github.com/Nyholm/psr7) & [Nyholm/psr7-server](https://github.com/Nyholm/psr7-server) - This is the fastest, strictest and most lightweight implementation available -- [Guzzle/psr7](https://github.com/guzzle/psr7) & [http-interop/http-factory-guzzle](https://github.com/http-interop/http-factory-guzzle) - This is the implementation used by the Guzzle Client, featuring extra functionality for stream and file handling +- [Guzzle/psr7](https://github.com/guzzle/psr7) - This is the implementation used by the Guzzle Client, featuring extra functionality for stream and file handling - [laminas-diactoros](https://github.com/laminas/laminas-diactoros) - This is the Laminas (Zend) PSR-7 implementation @@ -54,7 +54,7 @@ $app = AppFactory::create(); In order for auto-detection to work and enable you to use `AppFactory::create()` and `App::run()` without having to manually create a `ServerRequest` you need to install one of the following implementations: - [Slim-Psr7](https://github.com/slimphp/Slim-Psr7) - Install using `composer require slim/psr7` - [Nyholm/psr7](https://github.com/Nyholm/psr7) & [Nyholm/psr7-server](https://github.com/Nyholm/psr7-server) - Install using `composer require nyholm/psr7 nyholm/psr7-server` -- [Guzzle/psr7](https://github.com/guzzle/psr7) & [http-interop/http-factory-guzzle](https://github.com/http-interop/http-factory-guzzle) - Install using `composer require guzzlehttp/psr7 http-interop/http-factory-guzzle` +- [Guzzle/psr7](https://github.com/guzzle/psr7) - Install using `composer require guzzlehttp/psr7` - [laminas-diactoros](https://github.com/laminas/laminas-diactoros) - Install using `composer require laminas/laminas-diactoros` Then create file _public/index.php_. diff --git a/composer.json b/composer.json index 22d42bf0c..0d5a7a626 100644 --- a/composer.json +++ b/composer.json @@ -62,7 +62,7 @@ "nyholm/psr7-server": "^1.0", "phpspec/prophecy": "^1.13", "phpspec/prophecy-phpunit": "^2.0", - "phpstan/phpstan": "^0.12.94", + "phpstan/phpstan": "^0.12.96", "phpunit/phpunit": "^9.5", "slim/http": "^1.2", "slim/psr7": "^1.4", From d4809a4e5a9a3318c9a47d238558806c425def96 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Oct 2021 03:01:31 +0000 Subject: [PATCH 25/29] Update laminas/laminas-diactoros requirement from ^2.6 to ^2.8 Updates the requirements on [laminas/laminas-diactoros](https://github.com/laminas/laminas-diactoros) to permit the latest version. - [Release notes](https://github.com/laminas/laminas-diactoros/releases) - [Commits](https://github.com/laminas/laminas-diactoros/compare/2.6.0...2.8.0) --- updated-dependencies: - dependency-name: laminas/laminas-diactoros dependency-type: direct:development ... Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 0d5a7a626..920c9d726 100644 --- a/composer.json +++ b/composer.json @@ -57,7 +57,7 @@ "ext-simplexml": "*", "adriansuter/php-autoload-override": "^1.2", "guzzlehttp/psr7": "^2.0", - "laminas/laminas-diactoros": "^2.6", + "laminas/laminas-diactoros": "^2.8", "nyholm/psr7": "^1.4", "nyholm/psr7-server": "^1.0", "phpspec/prophecy": "^1.13", From 0cc114ee8bf0cfbd6b167d0d381c0747db717ae7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Oct 2021 03:01:37 +0000 Subject: [PATCH 26/29] Update phpspec/prophecy requirement from ^1.13 to ^1.14 Updates the requirements on [phpspec/prophecy](https://github.com/phpspec/prophecy) to permit the latest version. - [Release notes](https://github.com/phpspec/prophecy/releases) - [Changelog](https://github.com/phpspec/prophecy/blob/master/CHANGES.md) - [Commits](https://github.com/phpspec/prophecy/compare/1.13.0...1.14.0) --- updated-dependencies: - dependency-name: phpspec/prophecy dependency-type: direct:development ... Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 0d5a7a626..dd6af663c 100644 --- a/composer.json +++ b/composer.json @@ -60,7 +60,7 @@ "laminas/laminas-diactoros": "^2.6", "nyholm/psr7": "^1.4", "nyholm/psr7-server": "^1.0", - "phpspec/prophecy": "^1.13", + "phpspec/prophecy": "^1.14", "phpspec/prophecy-phpunit": "^2.0", "phpstan/phpstan": "^0.12.96", "phpunit/phpunit": "^9.5", From b7fc6df44847f96d3235cb7cbbfd3b0ea67b160d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Oct 2021 03:01:44 +0000 Subject: [PATCH 27/29] Update slim/psr7 requirement from ^1.4 to ^1.5 Updates the requirements on [slim/psr7](https://github.com/slimphp/Slim-Psr7) to permit the latest version. - [Release notes](https://github.com/slimphp/Slim-Psr7/releases) - [Commits](https://github.com/slimphp/Slim-Psr7/compare/1.4...1.5) --- updated-dependencies: - dependency-name: slim/psr7 dependency-type: direct:development ... Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 0d5a7a626..a3b2e2a9c 100644 --- a/composer.json +++ b/composer.json @@ -65,7 +65,7 @@ "phpstan/phpstan": "^0.12.96", "phpunit/phpunit": "^9.5", "slim/http": "^1.2", - "slim/psr7": "^1.4", + "slim/psr7": "^1.5", "squizlabs/php_codesniffer": "^3.6" }, "autoload": { From 5ccadfea94ad43288a5a24f847e51891298fd87b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Oct 2021 03:01:48 +0000 Subject: [PATCH 28/29] Update phpstan/phpstan requirement from ^0.12.96 to ^0.12.99 Updates the requirements on [phpstan/phpstan](https://github.com/phpstan/phpstan) to permit the latest version. - [Release notes](https://github.com/phpstan/phpstan/releases) - [Commits](https://github.com/phpstan/phpstan/compare/0.12.96...0.12.99) --- updated-dependencies: - dependency-name: phpstan/phpstan dependency-type: direct:development ... Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 0d5a7a626..894fcdb5e 100644 --- a/composer.json +++ b/composer.json @@ -62,7 +62,7 @@ "nyholm/psr7-server": "^1.0", "phpspec/prophecy": "^1.13", "phpspec/prophecy-phpunit": "^2.0", - "phpstan/phpstan": "^0.12.96", + "phpstan/phpstan": "^0.12.99", "phpunit/phpunit": "^9.5", "slim/http": "^1.2", "slim/psr7": "^1.4", From 03e6e68a961e0d314612f51b568a294b2d1aea73 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre=20B=C3=A9rub=C3=A9?= Date: Sat, 2 Oct 2021 13:05:02 -0600 Subject: [PATCH 29/29] remove Zend Diactoros references --- Slim/Factory/Psr17/Psr17FactoryProvider.php | 1 - .../Psr17/ZendDiactorosPsr17Factory.php | 19 ------------------- tests/Factory/AppFactoryTest.php | 3 --- .../ServerRequestCreatorFactoryTest.php | 3 --- 4 files changed, 26 deletions(-) delete mode 100644 Slim/Factory/Psr17/ZendDiactorosPsr17Factory.php diff --git a/Slim/Factory/Psr17/Psr17FactoryProvider.php b/Slim/Factory/Psr17/Psr17FactoryProvider.php index 113ee432e..a17670e4b 100644 --- a/Slim/Factory/Psr17/Psr17FactoryProvider.php +++ b/Slim/Factory/Psr17/Psr17FactoryProvider.php @@ -23,7 +23,6 @@ class Psr17FactoryProvider implements Psr17FactoryProviderInterface SlimPsr17Factory::class, NyholmPsr17Factory::class, LaminasDiactorosPsr17Factory::class, - ZendDiactorosPsr17Factory::class, GuzzlePsr17Factory::class, ]; diff --git a/Slim/Factory/Psr17/ZendDiactorosPsr17Factory.php b/Slim/Factory/Psr17/ZendDiactorosPsr17Factory.php deleted file mode 100644 index 779e761e7..000000000 --- a/Slim/Factory/Psr17/ZendDiactorosPsr17Factory.php +++ /dev/null @@ -1,19 +0,0 @@ -