diff options
| -rw-r--r-- | src/loader.js | 4 | ||||
| -rw-r--r-- | test/loaderSpec.js | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/src/loader.js b/src/loader.js index 7e2289d0..712ff0f7 100644 --- a/src/loader.js +++ b/src/loader.js @@ -70,7 +70,9 @@ function setupModuleLoader(window) { } return ensure(modules, name, function() { if (!requires) { - throw minErr('$injector')('nomod', "Module '{0}' is not available! You either misspelled the module name or forgot to load it.", name); + throw minErr('$injector')('nomod', "Module '{0}' is not available! You either misspelled the module name " + + "or forgot to load it. If registering a module ensure that you specify the dependencies as the second " + + "argument.", name); } /** @type {!Array.<Array.<*>>} */ diff --git a/test/loaderSpec.js b/test/loaderSpec.js index ce98c50a..73e94215 100644 --- a/test/loaderSpec.js +++ b/test/loaderSpec.js @@ -68,6 +68,8 @@ describe('module loader', function() { it('should complain of no module', function() { expect(function() { window.angular.module('dontExist'); - }).toThrow("[$injector:nomod] Module 'dontExist' is not available! You either misspelled the module name or forgot to load it."); + }).toThrow("[$injector:nomod] Module 'dontExist' is not available! You either misspelled the module name " + + "or forgot to load it. If registering a module ensure that you specify the dependencies as the second " + + "argument."); }); }); |
