* @private
*/
function replaceInternalLinks( $s ) {
+ if( $this->getTitle()->isCssOrJsPage() ) {
+ # bug 32450 : js and script pages in MediaWiki: namespace do not want
+ # to get their code or comments altered. Think about js string:
+ # var foobar = "[[Category:" + $catname + "]];
+ return $s;
+ }
$this->mLinkHolders->merge( $this->replaceInternalLinks2( $s ) );
return $s;
}
if ( $ns == NS_CATEGORY ) {
wfProfileIn( __METHOD__."-category" );
- if( $this->getTitle()->isCssOrJsPage() ) {
- # bug 32450 : js and script pages in MediaWiki: namespace do not want
- # to get their code or comments altered. Think about js string:
- # var foobar = "[[Category:" + $catname + "]];
- $s .= "[[$text]]$trail";
- wfProfileOut( __METHOD__."-category" );
- continue;
- }
$s = rtrim( $s . "\n" ); # bug 87
if ( $wasblank ) {