DWN-39926 : amend exception name in log messages

pull/1601/head
Harry Smith 2023-01-04 08:41:49 +00:00
parent b6f361b627
commit 0bea906f1e
1 changed files with 4 additions and 4 deletions

View File

@ -105,9 +105,9 @@ public class WhitelistAPI {
whitelist = gson.fromJson(json, WhitelistedSite.class);
validateWhitelistScopes(whitelist.getAllowedScopes());
} catch (WhitelistScopesException e) {
logger.error("addNewWhitelistedSite failed due to WhitelistException. {}", e.getMessage());
logger.error("addNewWhitelistedSite failed due to WhitelistScopesException. {}", e.getMessage());
m.addAttribute(HttpCodeView.CODE, HttpStatus.BAD_REQUEST);
m.addAttribute(JsonErrorView.ERROR_MESSAGE, "Could not save new whitelisted site. The server encountered a whitelist exception. Contact a system administrator for assistance.");
m.addAttribute(JsonErrorView.ERROR_MESSAGE, "Could not save new whitelisted site. The server encountered a whitelist scopes exception. Contact a system administrator for assistance.");
return JsonErrorView.VIEWNAME;
} catch (JsonParseException e) {
logger.error("addNewWhitelistedSite failed due to JsonParseException", e);
@ -147,9 +147,9 @@ public class WhitelistAPI {
whitelist = gson.fromJson(json, WhitelistedSite.class);
validateWhitelistScopes(whitelist.getAllowedScopes());
} catch (WhitelistScopesException e) {
logger.error("addNewWhitelistedSite failed due to WhitelistScopeException. {}", e.getMessage());
logger.error("addNewWhitelistedSite failed due to WhitelistScopesException. {}", e.getMessage());
m.addAttribute(HttpCodeView.CODE, HttpStatus.BAD_REQUEST);
m.addAttribute(JsonErrorView.ERROR_MESSAGE, "Could not save new whitelisted site. The server encountered a whitelist scope exception. Contact a system administrator for assistance.");
m.addAttribute(JsonErrorView.ERROR_MESSAGE, "Could not save new whitelisted site. The server encountered a whitelist scopes exception. Contact a system administrator for assistance.");
return JsonErrorView.VIEWNAME;
} catch (JsonParseException e) {
logger.error("updateWhitelistedSite failed due to JsonParseException", e);