Fix logging for angular bootstrapping errors (#10059)

This commit is contained in:
Charles Gagnon
2020-04-17 14:51:44 -07:00
committed by GitHub
parent b3492e3f57
commit 5304d65586

View File

@@ -46,6 +46,7 @@ export function bootstrapAngular<T>(accessor: ServicesAccessor, moduleType: IMod
let selector = document.createElement(uniqueSelectorString);
container.appendChild(selector);
const instantiationService = accessor.get(IInstantiationService);
const logService = accessor.get(ILogService);
if (!platform) {
instantiationService.invokeFunction((accessor) => {
@@ -67,7 +68,6 @@ export function bootstrapAngular<T>(accessor: ServicesAccessor, moduleType: IMod
callbackSetModule(moduleRef);
}
}).catch((e) => {
const logService = accessor.get(ILogService);
logService.error(e);
});