diff --git a/modules/@angular/platform-browser/src/browser/browser_adapter.ts b/modules/@angular/platform-browser/src/browser/browser_adapter.ts index d78a96320c..4ee77707ed 100644 --- a/modules/@angular/platform-browser/src/browser/browser_adapter.ts +++ b/modules/@angular/platform-browser/src/browser/browser_adapter.ts @@ -79,7 +79,11 @@ export class BrowserDomAdapter extends GenericBrowserDomAdapter { // TODO(tbosch): move this into a separate environment class once we have it logError(error: string): void { if (window.console) { - (window.console.error || window.console.log)(error); + if (console.error) { + console.error(error); + } else { + console.log(error); + } } } @@ -93,7 +97,6 @@ export class BrowserDomAdapter extends GenericBrowserDomAdapter { logGroup(error: string): void { if (window.console) { window.console.group && window.console.group(error); - this.logError(error); } }