From 358a683f381aa8eb7edd4886d6bdfe7ada61ec35 Mon Sep 17 00:00:00 2001 From: Omar Ajoue Date: Wed, 6 Apr 2022 13:55:10 +0200 Subject: [PATCH] fix(core): Fix issue with falsely skip authorizing (#3087) --- packages/cli/src/UserManagement/UserManagementHelper.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/cli/src/UserManagement/UserManagementHelper.ts b/packages/cli/src/UserManagement/UserManagementHelper.ts index e54850f92f..7b33640ae3 100644 --- a/packages/cli/src/UserManagement/UserManagementHelper.ts +++ b/packages/cli/src/UserManagement/UserManagementHelper.ts @@ -201,7 +201,7 @@ export async function checkPermissionsForExecution( export function isAuthExcluded(url: string, ignoredEndpoints: string[]): boolean { return !!ignoredEndpoints .filter(Boolean) // skip empty paths - .find((ignoredEndpoint) => url.includes(ignoredEndpoint)); + .find((ignoredEndpoint) => url.startsWith(`/${ignoredEndpoint}`)); } /**