diff --git a/ngapp/src/app/core/api.service.ts b/ngapp/src/app/core/api.service.ts index 1ffc73d1..4db9955d 100644 --- a/ngapp/src/app/core/api.service.ts +++ b/ngapp/src/app/core/api.service.ts @@ -88,6 +88,8 @@ export abstract class ApiService { msg = body.message; else if (body.error) msg = body.error; + else if (body.Information && body.Information.ErrorMessage1) + msg = body.Information.ErrorMessage1; } if (msg.length === 0 ) { diff --git a/ngapp/src/app/dataservices/shared/vdb.service.ts b/ngapp/src/app/dataservices/shared/vdb.service.ts index 51464cdc..edbe9daa 100644 --- a/ngapp/src/app/dataservices/shared/vdb.service.ts +++ b/ngapp/src/app/dataservices/shared/vdb.service.ts @@ -176,7 +176,12 @@ export class VdbService extends ApiService { .post(environment.komodoTeiidUrl + VdbsConstants.vdbRootPath, { path: vdbPath}, this.getAuthRequestOptions()) .map((response) => { - return response.ok; + let status = response.json(); + if (status.Information.deploymentSuccess !== 'true') { + this.handleError(response); + } + + return status.Information.deploymentSuccess === 'true'; }) .catch( ( error ) => this.handleError( error ) ); }