fix: Update test code to type-check under TS 2.5 (#20175)
PR Close #20175
This commit is contained in:
@ -399,7 +399,7 @@ export class UpgradeAdapter {
|
||||
|
||||
Promise.all([this.ng2BootstrapDeferred.promise, ng1BootstrapPromise]).then(([ng1Injector]) => {
|
||||
angular.element(element).data !(controllerKey(INJECTOR_KEY), this.moduleRef !.injector);
|
||||
this.moduleRef !.injector.get(NgZone).run(
|
||||
this.moduleRef !.injector.get<NgZone>(NgZone).run(
|
||||
() => { (<any>upgrade)._bootstrapDone(this.moduleRef, ng1Injector); });
|
||||
}, onError);
|
||||
return upgrade;
|
||||
|
@ -67,7 +67,7 @@ export class UpgradeNg1ComponentAdapterBuilder {
|
||||
|
||||
extractBindings() {
|
||||
const btcIsObject = typeof this.directive !.bindToController === 'object';
|
||||
if (btcIsObject && Object.keys(this.directive !.scope).length) {
|
||||
if (btcIsObject && Object.keys(this.directive !.scope !).length) {
|
||||
throw new Error(
|
||||
`Binding definitions on scope and controller at the same time are not supported.`);
|
||||
}
|
||||
|
Reference in New Issue
Block a user