The Wayback Machine - https://web.archive.org/web/20220807023446/https://github.com/symfony/symfony/pull/46985
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

[DoctrineBridge] Avoid calling AbstractPlatform::hasNativeGuidType() #46985

Merged
merged 1 commit into from Jul 20, 2022

Conversation

derrabus
Copy link
Member

@derrabus derrabus commented Jul 19, 2022

Q A
Branch? 5.4
Bug fix? yes
New feature? no
Deprecations? no
Tickets Follows doctrine/dbal#5509, alternative to doctrine/dbal#5518
License MIT
Doc PR N/A

AbstractPlatform::hasNativeGuidType() has been deprecated in Doctrine DBAL. This PR inlines the logic of that method where we need it.

Furthermore, I took the liberty to refactor the corresponding tests a little. We don't really need to mock AbstractPlatform because we can work with actual instances. This also allows us to test the behavior of our implementation on different platforms.

@derrabus derrabus requested review from nicolas-grekas and chalasr Jul 19, 2022
@carsonbot carsonbot changed the title Avoid calling AbstractPlatform::hasNativeGuidType() [DoctrineBridge] Avoid calling AbstractPlatform::hasNativeGuidType() Jul 19, 2022
@carsonbot carsonbot added the Bug label Jul 19, 2022
@carsonbot carsonbot added this to the 5.4 milestone Jul 19, 2022
@chalasr
Copy link
Member

@chalasr chalasr commented Jul 19, 2022

👍 for this with stof's suggestion as it makes the code more efficient and future proof than it is currently.

@derrabus derrabus force-pushed the bugfix/dbal-uid-deprecation branch from f01c9a4 to 5d882ce Compare Jul 19, 2022
fabpot
fabpot approved these changes Jul 20, 2022
@fabpot
Copy link
Member

@fabpot fabpot commented Jul 20, 2022

Thank you @derrabus.

@fabpot fabpot merged commit 47cb70b into symfony:5.4 Jul 20, 2022
4 of 11 checks passed
@derrabus derrabus deleted the bugfix/dbal-uid-deprecation branch Jul 20, 2022
This was referenced Jul 29, 2022
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.

None yet

6 participants