jenkins-bot has submitted this change and it was merged. (
https://gerrit.wikimedia.org/r/352990 )
Change subject: Fix styles queue violation for "ext.codereview.local"
......................................................................
Fix styles queue violation for "ext.codereview.local"
This module only contains a stylesheet and is only loaded through
addModuleStyles(). No problem there.
However, it sub classes ResourceLoaderWikiModule::getPages without
setting ResourceLoaderWikiModule::getType, which means it is still
registered as a 'general' module instead of a 'styles' module.
Instead of adding a getType method, just remove this class since
all it does is set a simple page name, which can be done by simply
creating a WikiModule instance directly, and also ensures getType is
set correctly.
Bug: T92459
Change-Id: Ifd70b7a34a3bba84363179ff987d43c1b7fc3337
---
D ResourceLoaderCodeReviewModule.php
M extension.json
2 files changed, 5 insertions(+), 22 deletions(-)
Approvals:
Aaron Schulz: Looks good to me, approved
jenkins-bot: Verified
diff --git a/ResourceLoaderCodeReviewModule.php
b/ResourceLoaderCodeReviewModule.php
deleted file mode 100644
index bfef606..0000000
--- a/ResourceLoaderCodeReviewModule.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-/**
- * Custom ResourceLoader module that loads a CodeReview.css per-wiki.
- *
- * Based on the SyntaxHighlight GeSHi extension's similar module by Roan
Kattouw.
- *
- * @file
- */
-class ResourceLoaderCodeReviewModule extends ResourceLoaderWikiModule {
- /**
- * @param $context ResourceLoaderContext
- * @return array
- */
- protected function getPages( ResourceLoaderContext $context ) {
- return array(
- 'MediaWiki:CodeReview.css' => array( 'type' => 'style'
),
- );
- }
-}
diff --git a/extension.json b/extension.json
index f6bc8d1..614cba3 100644
--- a/extension.json
+++ b/extension.json
@@ -114,7 +114,10 @@
},
"ext.codereview.local": {
"position": "top",
- "class": "ResourceLoaderCodeReviewModule"
+ "class": "ResourceLoaderWikiModule",
+ "styles": [
+ "MediaWiki:CodeReview.css"
+ ]
}
},
"ResourceFileModulePaths": {
@@ -207,8 +210,7 @@
"SvnRevStatusTablePager": "ui/CodeRevisionStatusView.php",
"SvnRevTagTablePager": "ui/CodeRevisionTagView.php",
"CodeStatusChangeTablePager": "ui/CodeStatusChangeListView.php",
- "CodeReviewHooks": "CodeReviewHooks.php",
- "ResourceLoaderCodeReviewModule":
"ResourceLoaderCodeReviewModule.php"
+ "CodeReviewHooks": "CodeReviewHooks.php"
},
"manifest_version": 1
}
--
To view, visit https://gerrit.wikimedia.org/r/352990
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ifd70b7a34a3bba84363179ff987d43c1b7fc3337
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/CodeReview
Gerrit-Branch: master
Gerrit-Owner: Krinkle <[email protected]>
Gerrit-Reviewer: Aaron Schulz <[email protected]>
Gerrit-Reviewer: Chad <[email protected]>
Gerrit-Reviewer: Reedy <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits