diff --git a/src/app/common/error-handlers/toaster-error-handler.ts b/src/app/common/error-handlers/toaster-error-handler.ts index fe1eca1b..555cb22c 100644 --- a/src/app/common/error-handlers/toaster-error-handler.ts +++ b/src/app/common/error-handlers/toaster-error-handler.ts @@ -4,7 +4,8 @@ import { ToasterService } from '../../services/toaster.service'; export class ToasterErrorHandler extends RavenErrorHandler { handleError(err: any): void { super.handleError(err); - + if (!err) return; + const toasterService = this.injector.get(ToasterService); if (err.error && err.error.message) { toasterService.error(err.error.message);