diff --git a/app/assets/javascripts/discourse-loader.js b/app/assets/javascripts/discourse-loader.js index b80e3aac0c6..2d9f1d9f35f 100644 --- a/app/assets/javascripts/discourse-loader.js +++ b/app/assets/javascripts/discourse-loader.js @@ -135,8 +135,12 @@ var define, require, requirejs; } requirejs = require = function(name) { - var mod = registry[name] || registry[MOVED_MODULES[name]]; + if (MOVED_MODULES[name]) { + name = MOVED_MODULES[name]; + } + + var mod = registry[name]; if (mod && mod.callback instanceof Alias) { mod = registry[mod.callback.name];