diff --git a/src/services/NamingConstraintService.js b/src/services/NamingConstraintService.js index 9d7f94ea4..60012192a 100644 --- a/src/services/NamingConstraintService.js +++ b/src/services/NamingConstraintService.js @@ -264,7 +264,6 @@ class NamingConstraintService { folder.id, project.id, ); - this.clearFolderRuleCache(); return documents ?? []; } catch (error) { if (isResponse(error) && error.status === 404) { @@ -274,6 +273,8 @@ class NamingConstraintService { return []; } throw new RuntimeError(ERRORS.FOLDER_NAMING_CONSTRAINT_DELETE_ERROR, error); + } finally { + this.clearFolderRuleCache(); } }