From 7eda1bcad5aab8d2e38ad2247315d4f5d763dbd3 Mon Sep 17 00:00:00 2001 From: Vito Date: Tue, 10 Nov 2020 09:55:21 +0000 Subject: [PATCH] [ACS-827] - added whitelisted element and method for checking them (#6329) * [ACS-827] - added whitelisted element and method for checking them * [ACS-827] - changed method name with clear one * [ACS-827] - pr review changes Co-authored-by: Vito Albano --- lib/core/services/alfresco-api.service.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/core/services/alfresco-api.service.ts b/lib/core/services/alfresco-api.service.ts index 2d15386797..a9f8c13ded 100644 --- a/lib/core/services/alfresco-api.service.ts +++ b/lib/core/services/alfresco-api.service.ts @@ -48,6 +48,8 @@ export class AlfrescoApiService { lastConfig: AlfrescoApiConfig; + private excludedErrorUrl: string[] = ['api/enterprise/system/properties']; + getInstance(): AlfrescoApiCompatibility { return this.alfrescoApi; } @@ -152,4 +154,9 @@ export class AlfrescoApiService { isDifferentConfig(lastConfig: AlfrescoApiConfig, newConfig: AlfrescoApiConfig) { return JSON.stringify(lastConfig) !== JSON.stringify(newConfig); } + + isExcludedErrorListener(currentFullPath: string): boolean { + const formattedPath = currentFullPath.replace(this.lastConfig.hostBpm + '/' + this.lastConfig.contextRootBpm, ''); + return this.excludedErrorUrl.includes(formattedPath); + } }