mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
feat: allow dashes in privilege group names
This commit is contained in:
@@ -54,7 +54,7 @@ Groups.removeEphemeralGroups = function (groups) {
|
|||||||
return groups;
|
return groups;
|
||||||
};
|
};
|
||||||
|
|
||||||
var isPrivilegeGroupRegex = /^cid:\d+:privileges:[\w:]+$/;
|
var isPrivilegeGroupRegex = /^cid:\d+:privileges:[\w\-:]+$/;
|
||||||
Groups.isPrivilegeGroup = function (groupName) {
|
Groups.isPrivilegeGroup = function (groupName) {
|
||||||
return isPrivilegeGroupRegex.test(groupName);
|
return isPrivilegeGroupRegex.test(groupName);
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user