diff --git a/ui/src/app/shared/api/task.service.ts b/ui/src/app/shared/api/task.service.ts index 5e0b623ff..87504233c 100644 --- a/ui/src/app/shared/api/task.service.ts +++ b/ui/src/app/shared/api/task.service.ts @@ -172,8 +172,11 @@ export class TaskService { } }); } + const url = taskExecution?._links && taskExecution?._links['tasks/logs'] + ? taskExecution?._links['tasks/logs'].href : + UrlUtilities.calculateBaseApiUrl() + `tasks/logs/${taskExecution.externalExecutionId}?platformName=${platform}&schemaTarget=${taskExecution.schemaTarget}`; return this.httpClient - .get(taskExecution?._links['tasks/logs'].href, { + .get(url, { headers }) .pipe(catchError(ErrorUtils.catchError));