r59982 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r59981‎ | r59982 | r59983 >
Date:23:26, 11 December 2009
Author:dale
Status:deferred
Tags:
Comment:
opps (moved mwEmbed.js gadget check to correct location )
Modified paths:
  • /branches/js2-work/phase3/js2/mwEmbed/mwEmbed.js (modified) (history)

Diff [purge]

Index: branches/js2-work/phase3/js2/mwEmbed/mwEmbed.js
@@ -1615,7 +1615,7 @@
16161616 var mwpath = null;
16171617
16181618 // Check for direct include of the mwEmbed.js
1619 - if ( src.indexOf( 'mwEmbed.js' ) !== -1 && src.indexOf( 'MediaWiki:Gadget') == -1) {
 1619+ if ( src.indexOf( 'mwEmbed.js' ) !== -1 ) {
16201620 mwpath = src.substr( 0, src.indexOf( 'mwEmbed.js' ) );
16211621 }
16221622
@@ -1738,9 +1738,13 @@
17391739 // Check for mwEmbed.js and/or script loader
17401740 var src = js_elements[i].getAttribute( "src" );
17411741 if ( src ) {
1742 - if ( src.indexOf( 'mwEmbed.js' ) !== -1 || (
1743 - ( src.indexOf( 'mwScriptLoader.php' ) !== -1 || src.indexOf( 'jsScriptLoader.php' ) !== -1 )
1744 - && src.indexOf( 'mwEmbed' ) !== -1 ) ) // (check for class=mwEmbed script_loader call)
 1742+ if (
 1743+ ( src.indexOf( 'mwEmbed.js' ) !== -1 && src.indexOf( 'MediaWiki:Gadget') == -1 )
 1744+ ||
 1745+ (
 1746+ ( src.indexOf( 'mwScriptLoader.php' ) !== -1 || src.indexOf( 'jsScriptLoader.php' ) !== -1 )
 1747+ && src.indexOf( 'mwEmbed' ) !== -1 )
 1748+ )
17451749 {
17461750 mwEmbedSrc = src;
17471751 return mwEmbedSrc;

Status & tagging log