AC-282: Fix deprecation messages for Symfony 6#16
Merged
borilyordanov merged 4 commits intopaysera:masterfrom Mar 5, 2025
Merged
AC-282: Fix deprecation messages for Symfony 6#16borilyordanov merged 4 commits intopaysera:masterfrom
borilyordanov merged 4 commits intopaysera:masterfrom
Conversation
142e345 to
10e380d
Compare
10e380d to
d14dfda
Compare
0c05c5d to
dfbc22c
Compare
borilyordanov
approved these changes
Mar 5, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
voidtypehint for PayseraApiBundle::build was added to fix the deprecation message:PHP Deprecated: Method "Symfony\Component\HttpKernel\Bundle\Bundle::build()" might add "void" as a native return type declaration in the future. Do the same in child class "Paysera\Bundle\ApiBundle\PayseraApiBundle" now to avoid errors or add an explicit @return annotation to suppress this message. in /home/app/src/vendor/symfony/error-handler/DebugClassLoader.php on line 339AttributeClassLoaderdoesn't have$readerproperty anymore.Symfony 6.4 - https://github.com/symfony/routing/blob/6.4/Loader/AttributeClassLoader.php#L83
Symfony 7.2 - https://github.com/symfony/routing/blob/7.2/Loader/AttributeClassLoader.php#L54
But it's called inside
Paysera\Bundle\ApiBundle\Service\RoutingLoader\RoutingAttributeLoadercausing errorCall to a member function getClassAnnotations() on null.A check was added not to call the
$readerif it doesn't exist of is not an instance ofDoctrine\Common\Annotations\Reader.