Drobbins has uploaded a new change for review.
https://gerrit.wikimedia.org/r/144418
Change subject: add to allow Annotator to be enabled in more namespaces.
......................................................................
add to allow Annotator to be enabled in more namespaces.
Change-Id: If1a9413da0cfb5936587b1b06241532fbac932b2
---
M Annotator.hooks.php
M Annotator.php
2 files changed, 4 insertions(+), 3 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Annotator
refs/changes/18/144418/1
diff --git a/Annotator.hooks.php b/Annotator.hooks.php
index acb3b72..1364d12 100755
--- a/Annotator.hooks.php
+++ b/Annotator.hooks.php
@@ -45,9 +45,10 @@
/*
module is added only when then namespace matches
*/
- if( $skin->getTitle()->inNamespaces( array( NS_MAIN, NS_TALK,
NS_CATEGORY ) ) ) {
+ global $wgAnnotatorNamespaces;
+ if( $skin->getTitle()->inNamespaces( $wgAnnotatorNamespaces ) )
{
$output->addModules( 'ext.annotator' );
}
return true;
}
-}
\ No newline at end of file
+}
diff --git a/Annotator.php b/Annotator.php
index 0b54850..2853bbc 100755
--- a/Annotator.php
+++ b/Annotator.php
@@ -16,7 +16,7 @@
$dir = dirname( __FILE__ ) . '/';
$wgMessagesDirs['Annotator'] = __DIR__ . '/i18n';
$wgExtensionMessagesFiles['Annotator'] = $dir . 'Annotator.i18n.php';
-
+$wgAnnotatorNamespaces = array( NS_MAIN, NS_TALK, NS_CATEGORY );
//Resource Modules
$wgAnnotatorResourcePaths = array(
'localBasePath' => __DIR__ . '/modules',
--
To view, visit https://gerrit.wikimedia.org/r/144418
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: If1a9413da0cfb5936587b1b06241532fbac932b2
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Annotator
Gerrit-Branch: master
Gerrit-Owner: Drobbins <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits