Skip to content

Fix position of $enableXsdValidation in DoctrineOrmMappingsPass::createXmlMappingDriver#2190

Merged
ostrolucky merged 6 commits intodoctrine:3.2.xfrom
KDederichs:fix/2189
Dec 24, 2025
Merged

Fix position of $enableXsdValidation in DoctrineOrmMappingsPass::createXmlMappingDriver#2190
ostrolucky merged 6 commits intodoctrine:3.2.xfrom
KDederichs:fix/2189

Conversation

@KDederichs
Copy link
Contributor

@KDederichs KDederichs commented Dec 22, 2025

Fix by allowing $enableXsdValidation to contain an array. If it does trigger a deprecation and grab the correct $enableXsdValidation parameter via func_get_arg

Fixes #2189

@KDederichs KDederichs force-pushed the fix/2189 branch 3 times, most recently from 273a0c0 to 60fca85 Compare December 22, 2025 13:35
@GromNaN GromNaN changed the title fix: fix BC break Fix position of $enableXsdValidation in DoctrineOrmMappingsPass::createXmlMappingDriver Dec 23, 2025
Copy link
Member

@GromNaN GromNaN left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR.
A few changes to comply with doctrine standards, but it seems correct to me.

@KDederichs KDederichs force-pushed the fix/2189 branch 2 times, most recently from d477787 to ef89b36 Compare December 23, 2025 12:17
@GromNaN GromNaN added this to the 3.2.2 milestone Dec 23, 2025
Fix by allowing $enableXsdValidation to contain an array. If it does trigger a deprecation and grab the correct $enableXsdValidation parameter via func_get_arg
Fix by allowing $enableXsdValidation to contain an array. If it does trigger a deprecation and grab the correct $enableXsdValidation parameter via func_get_arg
@GromNaN GromNaN requested review from Copilot and greg0ire December 23, 2025 18:26
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes the parameter order issue in DoctrineOrmMappingsPass::createXmlMappingDriver by handling the deprecated $aliasMap parameter that was previously in the 4th position. The fix maintains backward compatibility while deprecating the old signature.

Key Changes

  • Added deprecation handling for the old method signature where $aliasMap was the 4th parameter
  • Modified the $enableXsdValidation parameter to accept bool|array to detect old usage
  • Properly extracts the intended $enableXsdValidation value when the deprecated signature is used

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@ostrolucky ostrolucky added the Bug label Dec 24, 2025
@ostrolucky ostrolucky merged commit af84173 into doctrine:3.2.x Dec 24, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[3.2] BC Break in DoctrineOrmMappingsPass::createXmlMappingDriver signature causing conflicts with ecosystem bundles

4 participants