Skip to content

Conversation

@czachor
Copy link

@czachor czachor commented Jan 20, 2026

Fixes PHP 8.0+ deprecation in src/Exception/MailchimpException.php, line: 62:

Deprecated: Optional parameter $status declared before required parameter $title is implicitly treated as a required

Simply replaced $status=0 with $status. Since a value is provided each time it is used and the default value is never used, this solution is not a breaking change.

czachor and others added 14 commits February 16, 2024 19:16
Didn't do anything in /spec and /tests.

PHP min. version set to 8.1.
Symfony min. version set to 6.3. Todo: check if lower version (6.1?) is working.
Controller is extending from AbstractController instead of Controller.
Removed some deprecations.
Added some code formatting (PSR).
Commands: added returns (Command::SUCCESS).
Micro-optimization: changed array_push($foo, $bar) to $foo[] = $bar (faster here).
Changed type comparison operators (!= -> !==).
Added function's return types.
Added property types.
SubscriberEvent and WebhookEvent: removed Symfony\Component\EventDispatcher\Event class (removed in Symfony 4?)
routing.yaml: changed "type: annotation" to "type: attributes".
A lot of small changes related to language level / Symfony version upgrade.
AbstractBundle instead of Bundle.
…\Component\Routing\Attribute\Route;

Renamed files to match Symfony conventions.
Remove not needed addAnnotatedClassesToCompile() call.
Remove default value from $status parameter to resolve PHP 8.0+ deprecation warning about optional parameters declared before required parameters..
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant