@mojaloop/security-bc-client-lib
Advanced tools
Comparing version 0.5.5 to 0.5.6
@@ -73,6 +73,6 @@ /***** | ||
if (resp.status === 401) { | ||
throw new security_bc_public_types_lib_1.UnauthorizedError(`Could not bootstrap privileges to Authentication Service - UnauthorizedError - ${await resp.text()}`); | ||
throw new security_bc_public_types_lib_1.UnauthorizedError(`Could not bootstrap privileges to Authorization Service - UnauthorizedError - ${await resp.text()}`); | ||
} | ||
else if (resp.status === 403) { | ||
throw new security_bc_public_types_lib_1.ForbiddenError(`Could not bootstrap privileges to Authentication Service - Forbidden - ${await resp.text()}`); | ||
throw new security_bc_public_types_lib_1.ForbiddenError(`Could not bootstrap privileges to Authorization Service - Forbidden - ${await resp.text()}`); | ||
} | ||
@@ -84,8 +84,8 @@ else if (resp.status === 200 || (ignoreDuplicateError === true && resp.status === 409)) { | ||
else { | ||
throw new Error("Could not bootstrap privileges to Authentication Service - http response code: " + resp.status); | ||
throw new Error("Could not bootstrap privileges to Authorization Service - http response code: " + resp.status); | ||
} | ||
} | ||
catch (err) { | ||
this._logger.error(err, "Could not bootstrap privileges to Authentication Service"); | ||
throw new Error(err?.message || "Could not bootstrap privileges to Authentication Service"); | ||
this._logger.error(err, "Could not bootstrap privileges to Authorization Service"); | ||
throw new Error(err?.message || "Could not bootstrap privileges to Authorization Service"); | ||
} | ||
@@ -113,8 +113,8 @@ } | ||
else { | ||
throw new Error("Invalid response from Authentication Service fetching role privileges association - http response code: " + resp.status); | ||
throw new Error("Invalid response from Authorization Service fetching role privileges association - http response code: " + resp.status); | ||
} | ||
} | ||
catch (err) { | ||
this._logger.error(err, "Could not fetch role privileges association from Authentication Service"); | ||
throw new Error(err?.message || "Unknown error fetching role privileges association from Authentication Service"); | ||
this._logger.error(err, "Could not fetch role privileges association from Authorization Service"); | ||
throw new Error(err?.message || "Unknown error fetching role privileges association from Authorization Service"); | ||
} | ||
@@ -121,0 +121,0 @@ } |
{ | ||
"name": "@mojaloop/security-bc-client-lib", | ||
"version": "0.5.5", | ||
"version": "0.5.6", | ||
"description": "Mojaloop security authentication and authorization client library", | ||
@@ -5,0 +5,0 @@ "license": "Apache-2.0", |
Sorry, the diff of this file is not supported yet
153329