Skip to content

Commit 6a7ed17

Browse files
authored
dep(symfony): Allow symfony 8 (#77)
1 parent 270c49b commit 6a7ed17

File tree

8 files changed

+21
-21
lines changed

8 files changed

+21
-21
lines changed

.github/workflows/ci.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
strategy:
2222
matrix:
2323
php-version:
24-
- "8.3"
24+
- "8.4"
2525

2626
steps:
2727
- name: "Checkout"
@@ -56,7 +56,7 @@ jobs:
5656
strategy:
5757
matrix:
5858
php-version:
59-
- "8.3"
59+
- "8.4"
6060

6161
steps:
6262
- name: "Checkout"
@@ -83,7 +83,7 @@ jobs:
8383
strategy:
8484
matrix:
8585
php-version:
86-
- "8.3"
86+
- "8.4"
8787

8888
steps:
8989
- name: "Checkout"
@@ -116,7 +116,7 @@ jobs:
116116
strategy:
117117
matrix:
118118
php-version:
119-
- "8.3"
119+
- "8.4"
120120

121121
steps:
122122
- name: "Checkout"

.php-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
8.3
1+
8.4

composer.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,15 @@
1313
"php": ">=8.3",
1414
"oskarstark/enum-helper": "^1.6",
1515
"psr/log": "^3.0",
16-
"storyblok/php-content-api-client": ">=1.9.0",
16+
"storyblok/php-content-api-client": ">=1.12.0",
1717
"storyblok/php-tiptap-extension": "^1.0",
18-
"symfony/config": "^6.0 || ^7.0",
19-
"symfony/dependency-injection": "^6.0 || ^7.0",
20-
"symfony/framework-bundle": "^6.0 || ^7.0",
21-
"symfony/http-client": "^6.0 || ^7.0",
22-
"symfony/http-kernel": "^6.0 || ^7.0",
18+
"symfony/config": "^6.0 || ^7.0 || ^8.0",
19+
"symfony/dependency-injection": "^6.0 || ^7.0 || ^8.0",
20+
"symfony/framework-bundle": "^6.0 || ^7.0 || ^8.0",
21+
"symfony/http-client": "^6.0 || ^7.0 || ^8.0",
22+
"symfony/http-kernel": "^6.0 || ^7.0 || ^8.0",
2323
"symfony/monolog-bundle": "^3.10",
24-
"symfony/string": "^6.0 || ^7.0",
24+
"symfony/string": "^6.0 || ^7.0 || ^8.0",
2525
"thecodingmachine/safe": "^2.0 || ^3.0",
2626
"twig/twig": "^3.20",
2727
"webmozart/assert": "^1.11"
@@ -36,7 +36,7 @@
3636
"phpstan/phpstan-webmozart-assert": "^2.0",
3737
"phpunit/phpunit": "^12",
3838
"rector/rector": "^2.0",
39-
"symfony/event-dispatcher": "^6.0 || ^7.1",
39+
"symfony/event-dispatcher": "^6.0 || ^7.1 || ^8.0",
4040
"thecodingmachine/phpstan-safe-rule": "^1.4"
4141
},
4242
"scripts": {

phpstan-baseline.neon

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ parameters:
2525
path: src/DataCollector/StoryblokCollector.php
2626

2727
-
28-
message: '#^Call to an undefined method Symfony\\Component\\Config\\Definition\\Builder\\NodeDefinition\:\:children\(\)\.$#'
29-
identifier: method.notFound
28+
message: '#^Method Storyblok\\Bundle\\DependencyInjection\\Configuration\:\:getConfigTreeBuilder\(\) return type with generic class Symfony\\Component\\Config\\Definition\\Builder\\TreeBuilder does not specify its types\: T$#'
29+
identifier: missingType.generics
3030
count: 1
3131
path: src/DependencyInjection/Configuration.php
3232

src/ContentType/Listener/GlobalCachingListener.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public function __construct(
3030

3131
public function __invoke(ResponseEvent $event): void
3232
{
33-
if ([] !== $event->getRequest()->get('_cache', [])) {
33+
if ([] !== $event->getRequest()->attributes->get('_cache', [])) {
3434
return;
3535
}
3636

src/ContentType/Listener/ResolveControllerListener.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,11 @@ public function __invoke(ControllerEvent $event): void
5454
return;
5555
}
5656

57-
if ($request->get('_route') !== Route::CONTENT_TYPE) {
57+
if ($request->attributes->get('_route') !== Route::CONTENT_TYPE) {
5858
return;
5959
}
6060

61-
$params = $request->get('_route_params', []);
61+
$params = $request->attributes->get('_route_params', []);
6262

6363
if (!\array_key_exists('slug', $params)) {
6464
return;

src/ContentType/Listener/StoryNotFoundExceptionListener.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,11 +47,11 @@ public function __invoke(ExceptionEvent $event): void
4747

4848
$request = $event->getRequest();
4949

50-
if ($request->get('_route') !== Route::CONTENT_TYPE) {
50+
if ($request->attributes->get('_route') !== Route::CONTENT_TYPE) {
5151
return;
5252
}
5353

54-
$params = $request->get('_route_params', []);
54+
$params = $request->attributes->get('_route_params', []);
5555

5656
if (!\array_key_exists('slug', $params)) {
5757
return;

src/DependencyInjection/Configuration.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public function getConfigTreeBuilder(): TreeBuilder
7777
->defaultNull()
7878
->end()
7979
->integerNode('smax_age')
80-
->defaultNull(3600)
80+
->defaultNull()
8181
->end()
8282
->end()
8383
->end()

0 commit comments

Comments
 (0)