mirror of
https://github.com/Hopiu/angular.js.git
synced 2026-03-17 07:40:22 +00:00
temporary backwards compatibility patch for
This commit is contained in:
parent
03df6cbddb
commit
692333f2f5
1 changed files with 5 additions and 0 deletions
|
|
@ -227,6 +227,11 @@ function createScope(parent, providers, instanceCache) {
|
|||
instance[name] = bind(instance, fn);
|
||||
});
|
||||
instance.$inject.apply(instance, concat([Class, instance], arguments, 1));
|
||||
|
||||
//TODO: backwards compatibility hack, remove when we don't depend on init methods
|
||||
if (isFunction(Class.prototype.init)) {
|
||||
instance.init();
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue