Last modified: 2011-02-17 17:08:37 UTC
The JS minification interprets // in regular expressions as beginning a comment and so removes following code. Example: if (/\/commons\//.test($this.find('img').attr('src'))) is minified to if(/\/commons\
Test case: http://translatewiki.net/wiki/MediaWiki:Modern.js?useskin=modern
http://translatewiki.net/w/load.php?debug=false&lang=nl&modules=site&only=scripts&skin=modern jQuery(document).ready(function($){ var $this=$('#content'); if(/\/commons\ |> SyntaxError: Parse error }); mediaWiki.loader.state({"site":"ready"});
This only fails for regexes which contain a slash at the end (causing //) AND contain a slash somewhere in the middle (causing the minifier to incorrectly regard it as the end of the regex). Fixed in r82340