Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix json_decode associative argument consistency with PHP #436

Closed
wants to merge 1 commit into from

Conversation

dpi
Copy link
Contributor

@dpi dpi commented Dec 27, 2023

I like to use named arguments with \json_decode(), particularly with the associative argument.

e.g. \json_decode($json, associative: true);

Switching to use thecodingmachine/safe currently necessitates switching associative to assoc. This slows down migrations and introduces an inconsistency.

We should fix the named argument of \Safe\json_decode so it has the same name as PHP.

@dpi
Copy link
Contributor Author

dpi commented Dec 27, 2023

Similar to #376

@dpi dpi changed the title Fix json_decode associative argument consistency with PHP Fix json_decode associative argument consistency with PHP Dec 27, 2023
@staabm
Copy link
Collaborator

staabm commented Nov 28, 2024

cherry-picked with #473

thank you

@staabm staabm closed this Nov 28, 2024
@dpi dpi deleted the json_decode-named-arg branch November 28, 2024 12:13
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.

2 participants