mirror of
https://github.com/NicolasConstant/sengi
synced 2025-02-02 19:46:59 +01:00
better error displaying
This commit is contained in:
parent
29aa5c7bbe
commit
3e54134c30
@ -15,10 +15,11 @@ export class NotificationService {
|
||||
}
|
||||
|
||||
public notifyHttpError(err: HttpErrorResponse){
|
||||
console.error(err);
|
||||
console.error(err.message);
|
||||
// let message = `${err.status}: ${err.statusText}`;
|
||||
let message = `${err.statusText}`;
|
||||
let message = 'Oops, Unknown Error' ;
|
||||
try{
|
||||
message = `Oops, Error ${err.status}`;
|
||||
console.error(err.message);
|
||||
} catch(err){}
|
||||
this.notify(message, true);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user