@nsshunt/stsfhirclient 2.0.48 → 2.0.50
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/stsfhirclient.cjs
CHANGED
|
@@ -10192,6 +10192,7 @@ var FhirRESTClient = class {
|
|
|
10192
10192
|
} catch (error) {
|
|
10193
10193
|
if (axios.default.isAxiosError(error)) {
|
|
10194
10194
|
const axiosError = error;
|
|
10195
|
+
if (axiosError.response.status === StatusCodes.UNAUTHORIZED) throw error;
|
|
10195
10196
|
return {
|
|
10196
10197
|
status: axiosError.response.status,
|
|
10197
10198
|
body: axiosError.response.data,
|
|
@@ -10254,6 +10255,7 @@ var FhirRESTClient = class {
|
|
|
10254
10255
|
} catch (error) {
|
|
10255
10256
|
if (axios.default.isAxiosError(error)) {
|
|
10256
10257
|
const axiosError = error;
|
|
10258
|
+
if (axiosError.response.status === StatusCodes.UNAUTHORIZED) throw error;
|
|
10257
10259
|
return {
|
|
10258
10260
|
status: axiosError.response.status,
|
|
10259
10261
|
body: axiosError.response.data,
|
|
@@ -10279,18 +10281,14 @@ var FhirRESTClient = class {
|
|
|
10279
10281
|
} catch (error) {
|
|
10280
10282
|
if (axios.default.isAxiosError(error)) {
|
|
10281
10283
|
const axiosError = error;
|
|
10282
|
-
if (axiosError.response
|
|
10283
|
-
|
|
10284
|
-
|
|
10285
|
-
|
|
10286
|
-
|
|
10287
|
-
|
|
10288
|
-
|
|
10289
|
-
|
|
10290
|
-
} else {
|
|
10291
|
-
this.LogError("DeleteResource", error);
|
|
10292
|
-
throw error;
|
|
10293
|
-
}
|
|
10284
|
+
if (axiosError.response.status === StatusCodes.UNAUTHORIZED) throw error;
|
|
10285
|
+
const versionNumber = this.ExtractNumber(versionIdETag) + 1;
|
|
10286
|
+
return {
|
|
10287
|
+
status: axiosError.response.status,
|
|
10288
|
+
body: axiosError.response.data,
|
|
10289
|
+
headers: { ETag: `W/"${versionNumber}"` }
|
|
10290
|
+
};
|
|
10291
|
+
} else throw error;
|
|
10294
10292
|
}
|
|
10295
10293
|
};
|
|
10296
10294
|
GetMetadata = async () => {
|