mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-07-31 17:38:28 +00:00
added try - catch in api and handleError methods
This commit is contained in:
@@ -48,4 +48,12 @@ export abstract class RepoApi {
|
||||
return this.username;
|
||||
}
|
||||
|
||||
protected handleError(message: string, response: any) {
|
||||
console.log(`\n--- ${message} error :`);
|
||||
console.log('\t>>> Status: ', response.status);
|
||||
console.log('\t>>> Text: ', response.response.text);
|
||||
console.log('\t>>> Method: ', response.response.error.method);
|
||||
console.log('\t>>> Path: ', response.response.error.path);
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user