Skip to content

Commit 8680535

Browse files
authored
Fix for PHP 8.4 (#5)
1 parent 63c4306 commit 8680535

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

.github/workflows/build.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ jobs:
3939
- "8.0"
4040
- "8.1"
4141
- "8.2"
42+
- "8.3"
43+
- "8.4"
4244

4345
steps:
4446
- name: Checkout.

.github/workflows/static.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ jobs:
3535
- "8.0"
3636
- "8.1"
3737
- "8.2"
38+
- "8.3"
3839

3940
steps:
4041
- name: Checkout.

src/Application.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ public function __construct(
6969
* @param ServerRequestInterface $request
7070
* @param RequestHandlerInterface|null $defaultHandler
7171
*/
72-
public function run(ServerRequestInterface $request, RequestHandlerInterface $defaultHandler = null): void
72+
public function run(ServerRequestInterface $request, ?RequestHandlerInterface $defaultHandler = null): void
7373
{
7474
(new ServerRequestRunner($this->pipeline, $this->emitter))->run($request, $defaultHandler ?? $this->default);
7575
}
@@ -82,7 +82,7 @@ public function run(ServerRequestInterface $request, RequestHandlerInterface $de
8282
* @param mixed $middleware any valid value for converting it to `Psr\Http\Server\MiddlewareInterface` instance.
8383
* @param string|null $path path prefix from the root to which the middleware is attached.
8484
*/
85-
public function pipe($middleware, string $path = null): void
85+
public function pipe($middleware, ?string $path = null): void
8686
{
8787
$this->pipeline->pipe($this->resolver->resolve($middleware), $path);
8888
}

src/Middleware/BodyParamsMiddleware.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,7 @@ final class BodyParamsMiddleware implements MiddlewareInterface
2727
*
2828
* @throws BadRequestHttpException
2929
* @link https://tools.ietf.org/html/rfc7231
30-
* @psalm-suppress MixedArgument
31-
* @psalm-suppress MixedAssignment
30+
* @psalm-suppress MixedArgument, MixedAssignment, RiskyTruthyFalsyComparison
3231
*/
3332
public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
3433
{

0 commit comments

Comments
 (0)