Added checkUnloaded call to registerModules. Minified using Google Closure Compiler.