-
Notifications
You must be signed in to change notification settings - Fork 3
Add fallback getDescription method for MW < 1.41 compat #192
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
Conversation
📝 Walkthrough""" WalkthroughThe changes update the Changes
Assessment against linked issues
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (3)
✅ Files skipped from review due to trivial changes (1)
🚧 Files skipped from review as they are similar to previous changes (2)
⏰ Context from checks skipped due to timeout of 90000ms (2)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (2)
src/EntryPoints/SpecialWikibaseExport.php (1)
41-49
: Implementation looks good with a minor suggestionThe changes correctly implement version-specific behavior for MediaWiki 1.41 compatibility. The docblock clearly explains the dual return types.
Consider simplifying the condition by using the null coalesce operator to handle cases where MW_VERSION might not be defined:
- if ( defined( 'MW_VERSION' ) && version_compare( MW_VERSION, '1.41', '>=' ) ) { + if ( defined( 'MW_VERSION' ) && version_compare( MW_VERSION ?? '0.0', '1.41', '>=' ) ) {🧰 Tools
🪛 GitHub Check: Static Analysis: MW REL1_43, PHP 8.3
[failure] 45-45:
Right side of && is always true.src/EntryPoints/SpecialWikibaseExportConfig.php (1)
31-39
: Implementation is consistent with SpecialWikibaseExportThe changes correctly implement version-specific behavior for MediaWiki 1.41 compatibility, maintaining consistency with the SpecialWikibaseExport class.
Similar to the suggestion for the other file, consider handling cases where MW_VERSION might not be defined:
- if ( defined( 'MW_VERSION' ) && version_compare( MW_VERSION, '1.41', '>=' ) ) { + if ( defined( 'MW_VERSION' ) && version_compare( MW_VERSION ?? '0.0', '1.41', '>=' ) ) {🧰 Tools
🪛 GitHub Check: Static Analysis: MW REL1_43, PHP 8.3
[failure] 35-35:
Right side of && is always true.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
src/EntryPoints/SpecialWikibaseExport.php
(1 hunks)src/EntryPoints/SpecialWikibaseExportConfig.php
(2 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (2)
src/EntryPoints/SpecialWikibaseExportConfig.php (1)
src/EntryPoints/SpecialWikibaseExport.php (1)
getDescription
(44-50)
src/EntryPoints/SpecialWikibaseExport.php (1)
src/EntryPoints/SpecialWikibaseExportConfig.php (1)
getDescription
(34-40)
🪛 GitHub Check: Static Analysis: MW REL1_43, PHP 8.3
src/EntryPoints/SpecialWikibaseExportConfig.php
[failure] 35-35:
Right side of && is always true.
src/EntryPoints/SpecialWikibaseExport.php
[failure] 45-45:
Right side of && is always true.
🔇 Additional comments (1)
src/EntryPoints/SpecialWikibaseExportConfig.php (1)
7-7
: Correct import of the Message classAppropriate addition of the Message class import to support the new return type.
Released |
Fixes: #191
Summary by CodeRabbit