r49579 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r49578‎ | r49579 | r49580 >
Date:22:28, 16 April 2009
Author:dale
Status:ok
Tags:
Comment:
switched from addScript() call to addScriptFile() call to support scriptLoader
Modified paths:
  • /trunk/extensions/Gadgets/Gadgets.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Gadgets/Gadgets.php
@@ -222,7 +222,8 @@
223223
224224 if ( preg_match( '/\.js/', $codePage ) ) {
225225 $u = $t->getLocalURL( 'action=raw&ctype=' . $wgJsMimeType );
226 - $out->addScript( '<script type="' . $wgJsMimeType . '" src="' . htmlspecialchars( $u ) . '"></script>' . "\n" );
 226+ //switched to addScriptFile call to support scriptLoader
 227+ $out->addScriptFile( $u );
227228 }
228229 else if ( preg_match( '/\.css/', $codePage ) ) {
229230 $u = $t->getLocalURL( 'action=raw&ctype=text/css' );

Status & tagging log