8000 Don't pass `false` as lock mode to `appendLockHint()` by derrabus · Pull Request #8937 · doctrine/orm · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Don't pass false as lock mode to appendLockHint() #8937

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
Aug 23, 2021

Conversation

derrabus
Copy link
Member

AbstractPlatform::appendLockHint() throws a TypeError in DBAL 3 if we pass false as $lockMode parameter. In DBAL 2, all platforms where the passed lock mode actually makes a difference execute some fallback logic for unknown lock modes (such as false) which is basically the same as the logic executed for LockMode::NONE.

This PR proposes to make that fallback explicit, so we don't run into a TypeError anymore.

@derrabus derrabus changed the title Don't pass false als lock mode to appendLockHint() Don't pass false as lock mode to appendLockHint() Aug 22, 2021
@derrabus derrabus force-pushed the bugfix/bool-lock-mode branch from 51a7ae6 to f0e784a Compare August 22, 2021 13:34
@derrabus derrabus added this to the 2.10.0 milestone Aug 23, 2021
@derrabus derrabus merged commit bbe0b17 into doctrine:2.10.x Aug 23, 2021
@derrabus derrabus deleted the bugfix/bool-lock-mode branch August 23, 2021 14:25
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
0