refactor(Completer): rename complete() to resolve()
This commit is contained in:
2
modules/angular2/src/core/application.js
vendored
2
modules/angular2/src/core/application.js
vendored
@ -125,7 +125,7 @@ export function bootstrap(appComponentType: Type, bindings: List<Binding>=null,
|
||||
lc.registerWith(zone, rootView.changeDetector);
|
||||
lc.tick(); //the first tick that will bootstrap the app
|
||||
|
||||
bootstrapProcess.complete(appInjector);
|
||||
bootstrapProcess.resolve(appInjector);
|
||||
},
|
||||
|
||||
(err) => {
|
||||
|
@ -11,7 +11,7 @@ export class XHRImpl extends XHR {
|
||||
xhr.onload = function() {
|
||||
var status = xhr.status;
|
||||
if (200 <= status && status <= 300) {
|
||||
completer.complete(xhr.responseText);
|
||||
completer.resolve(xhr.responseText);
|
||||
} else {
|
||||
completer.reject(`Failed to load ${url}`);
|
||||
}
|
||||
|
Reference in New Issue
Block a user