From b8f2800dab653abbdc9a713128e2ed22cb2b6aca Mon Sep 17 00:00:00 2001 From: webplusai Date: Tue, 24 Dec 2024 12:01:18 +0000 Subject: [PATCH] #8862 fix bug with ACL permissions (#8864) --- .../multiwikiserver/modules/store/sql-tiddler-database.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/tiddlywiki/multiwikiserver/modules/store/sql-tiddler-database.js b/plugins/tiddlywiki/multiwikiserver/modules/store/sql-tiddler-database.js index 0c8fe8237..14f8641f4 100644 --- a/plugins/tiddlywiki/multiwikiserver/modules/store/sql-tiddler-database.js +++ b/plugins/tiddlywiki/multiwikiserver/modules/store/sql-tiddler-database.js @@ -569,7 +569,7 @@ SqlTiddlerDatabase.prototype.checkACLPermission = function(userId, entityType, e const aclRecord = aclRecords.find(record => record.permission_name === permissionName); // If no ACL record exists, return true for hasPermission - if ((!aclRecord && !ownerId) || ((!!aclRecord && !!ownerId) && ownerId === userId)) { + if ((!aclRecord && !ownerId && aclRecords.length === 0) || ((!!aclRecord && !!ownerId) && ownerId === userId)) { return true; }