diff options
author | Ted Trask <ttrask01@yahoo.com> | 2012-01-19 21:47:09 +0000 |
---|---|---|
committer | Ted Trask <ttrask01@yahoo.com> | 2012-01-19 21:47:09 +0000 |
commit | 8cbd5764dc499274a0fd2f97717dfa1de121788a (patch) | |
tree | 1b657dc53bb801c17600f091ab90c4a0bfc55267 /lib | |
parent | 1e53255088385fcfe49747202227d30a76e08c89 (diff) | |
download | acf-core-8cbd5764dc499274a0fd2f97717dfa1de121788a.tar.bz2 acf-core-8cbd5764dc499274a0fd2f97717dfa1de121788a.tar.xz |
Must allow roles to have '-' character
Diffstat (limited to 'lib')
-rw-r--r-- | lib/roles.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/roles.lua b/lib/roles.lua index 8cc5332..0cfd382 100644 --- a/lib/roles.lua +++ b/lib/roles.lua @@ -299,8 +299,8 @@ set_role_perm = function(self, role, permissions, permissions_array) if role==nil or role=="" then return false, "Invalid Role" end - if string.find(role, '[^%w_/]') then - return false, "Role can only contain letters, numbers, '/', and '_'" + if string.find(role, '[^%w_/-]') then + return false, "Role can only contain letters, numbers, '/', '-', and '_'" end if permissions and not permissions_array then permissions_array = {} |