From: Krinkle Date: Wed, 18 May 2011 20:31:28 +0000 (+0000) Subject: Changing console.log(e) to a throw. console.log makes it go toString() which is prett... X-Git-Tag: 1.31.0-rc.0~30084 X-Git-Url: http://git.cyclocoop.org/fichier?a=commitdiff_plain;h=bdac16978c6827bb5d8709071ee8afb99707ec3e;p=lhc%2Fweb%2Fwiklou.git Changing console.log(e) to a throw. console.log makes it go toString() which is pretty much the same as the e.message in the console.log call above it. This also made it impossible for QUnit to get it's hand on the actual error. Fixed it by moing it outside of the if statement so it can be caught. --- diff --git a/resources/mediawiki/mediawiki.js b/resources/mediawiki/mediawiki.js index 0533baf6fd..de7a2cd668 100644 --- a/resources/mediawiki/mediawiki.js +++ b/resources/mediawiki/mediawiki.js @@ -509,8 +509,8 @@ window.mediaWiki = new ( function( $ ) { // and not in debug mode, such as when a symbol that should be global isn't exported if ( window.console && typeof window.console.log === 'function' ) { console.log( _fn + 'Exception thrown by ' + module + ': ' + e.message ); - console.log( e ); } + throw e; registry[module].state = 'error'; } }