Skip to content

Fix legacy cookie defaults deprecations#24

Merged
stof merged 1 commit intominkphp:masterfrom
artursvonda:support-symfony-5.0-cookies
Nov 30, 2018
Merged

Fix legacy cookie defaults deprecations#24
stof merged 1 commit intominkphp:masterfrom
artursvonda:support-symfony-5.0-cookies

Conversation

@artursvonda
Copy link
Copy Markdown
Contributor

Fixes deprecation from latest Symfony version

The default value of the "$secure" and "$samesite" arguments of "Symfony\Component\HttpFoundation\Cookie::__construct"'s constructor will respectively change from "false" to "null" and from "null" to "lax" in Symfony 5.0, you should define their values explicitly or use "Cookie::create()" instead.

Supports both current (constructor) version and suggested Cookie::create factory.

Since supported PHP version is 5.3.x+, couldn't use Cookie::class constant so instead used string of class name.

@artursvonda
Copy link
Copy Markdown
Contributor Author

No idea why composer check failed in Scrutinizer since I didn't change anything.

@stof
Copy link
Copy Markdown
Member

stof commented Nov 30, 2018

Thanks @artursvonda

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