diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/ng/controller.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/ng/controller.js b/src/ng/controller.js index fa90f8cd..67f70aad 100644 --- a/src/ng/controller.js +++ b/src/ng/controller.js @@ -23,7 +23,11 @@ function $ControllerProvider() { * annotations in the array notation). */ this.register = function(name, constructor) { - controllers[name] = constructor; + if (isObject(name)) { + extend(controllers, name) + } else { + controllers[name] = constructor; + } }; |
