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

[CMSP-881] use version_compare #120

Merged
merged 2 commits into from
Mar 14, 2024
Merged

Conversation

jazzsequence
Copy link
Contributor

Overview

This pull request:

  • changes the > for comparing WP-CLI versions to version_compare
Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? yes/no (2.10 is no longer < 2.9? 🧌)

Summary

> does not work when 2.10 is equivalent to 2.1 instead of the next value after 2.9.

version_compare is more robust and purpose-built for this use case.

because just > does not work when 2.10 is equivalent to 2.1 instead of the next value after 2.9
@jazzsequence jazzsequence requested a review from a team as a code owner March 14, 2024 16:37
src/Cli/FrameworkCommands.php Outdated Show resolved Hide resolved
@jazzsequence jazzsequence merged commit 7d4072a into master Mar 14, 2024
2 checks passed
@jazzsequence jazzsequence deleted the CMSP-881-version-compare branch March 14, 2024 17:06
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