From 44d582575af34dbdcb1a6b7512c2d62b8983ee03 Mon Sep 17 00:00:00 2001 From: "Mariana R. Santos" Date: Tue, 17 Dec 2024 16:06:22 +0100 Subject: [PATCH] Call IDA in behalf of the app --- backend/api/Services/InspectionService.cs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/backend/api/Services/InspectionService.cs b/backend/api/Services/InspectionService.cs index c51df67b..9d05fe33 100644 --- a/backend/api/Services/InspectionService.cs +++ b/backend/api/Services/InspectionService.cs @@ -114,7 +114,7 @@ private IQueryable GetInspections(bool readOnly = true) { string relativePath = $"InspectionData/{inspectionId}/inspection-data-storage-location"; - var response = await idaApi.CallApiForUserAsync( + var response = await idaApi.CallApiForAppAsync( ServiceName, options => { @@ -123,7 +123,6 @@ private IQueryable GetInspections(bool readOnly = true) } ); - if (response.StatusCode == HttpStatusCode.Accepted) { logger.LogInformation("Inspection data storage location for inspection with Id {inspectionId} is not yet available", inspectionId);