From 814f6d4dc2fc3e0140ce32253bd09ae021eca59b Mon Sep 17 00:00:00 2001 From: BlackDex Date: Tue, 28 Jan 2025 15:02:36 +0100 Subject: [PATCH] Allow all manager to create collections again This commit checks if the member is a manager or better, and if so allows it to createCollections. We actually check if it is less then a Manager, since the `limitCollectionCreation` should be set to false to allow it and true to prevent. This should fix an issue discussed in #5484 Signed-off-by: BlackDex --- src/db/models/organization.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/db/models/organization.rs b/src/db/models/organization.rs index aa3e1d01..2b54e1d0 100644 --- a/src/db/models/organization.rs +++ b/src/db/models/organization.rs @@ -464,7 +464,7 @@ impl Membership { "familySponsorshipValidUntil": null, "familySponsorshipToDelete": null, "accessSecretsManager": false, - "limitCollectionCreation": true, + "limitCollectionCreation": self.atype < MembershipType::Manager, // If less then a manager return true, to limit collection creations "limitCollectionCreationDeletion": true, "limitCollectionDeletion": true, "allowAdminAccessToAllCollectionItems": true,