Skip to content

[Console] Make sure $maxAttempts is an int or null #38080

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

Merged
merged 1 commit into from
Sep 7, 2020

Conversation

derrabus
Copy link
Member

@derrabus derrabus commented Sep 6, 2020

Q A
Branch? 4.4
Bug fix? yes
New feature? no
Deprecations? no
Tickets #36872
License MIT
Doc PR N/A

The behavior of the "less than" operator for mixed types has changed in php 8. It is now possible to call setMaxAttempts() with a random string without raising the expected InvalidArgumentException. I've added an explicit type cast in order to restore the previous behavior.

@chalasr chalasr added this to the 4.4 milestone Sep 7, 2020
@fabpot fabpot changed the base branch from 4.4 to 3.4 September 7, 2020 05:00
@fabpot fabpot force-pushed the bugfix/max-attempts-int branch from b81e280 to 4fcd491 Compare September 7, 2020 05:00
@fabpot
Copy link
Member

fabpot commented Sep 7, 2020

Thank you @derrabus.

@fabpot fabpot merged commit 0afa250 into symfony:3.4 Sep 7, 2020
@derrabus derrabus deleted the bugfix/max-attempts-int branch September 7, 2020 08:59
This was referenced Sep 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants