Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

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

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
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.

@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 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 2 times, most recently from dba6e86 to f01c9a4 Compare July 19, 2022 17:02
src/Symfony/Bridge/Doctrine/Types/AbstractUidType.php Outdated Show resolved Hide resolved
@derrabus derrabus force-pushed the bugfix/dbal-uid-deprecation branch from f01c9a4 to 5d882ce Compare July 19, 2022 17:12
@fabpot
Copy link
Member

fabpot commented Jul 20, 2022

Thank you @derrabus.

@fabpot fabpot merged commit 47cb70b into symfony:5.4 Jul 20, 2022
@derrabus derrabus deleted the bugfix/dbal-uid-deprecation branch July 20, 2022 08:32
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.

6 participants
Morty Proxy This is a proxified and sanitized view of the page, visit original site.