Fix json_decode to handle null body response#47
Open
czachor wants to merge 17 commits intowelpdev:masterfrom
Open
Fix json_decode to handle null body response#47czachor wants to merge 17 commits intowelpdev:masterfrom
czachor wants to merge 17 commits intowelpdev:masterfrom
Conversation
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..
Fix deprecated optional parameter before required
Sometimes Mailchimp returns null body.
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.
Sometimes Mailchimp returns null body for unknown reason. In my case it was connected to
GET lists/{LIST_ID}/members/endpoint when an "Syntax error" is returned from Mailchimp (in cases like invalid or mispelled email).When it happens, since PHP 8.1 an error is thrown in
throwMailchimpErrormethod inWelp\MailchimpBundle\Subscriber\ListRepository: