summaryrefslogtreecommitdiff
path: root/misc/freeswitch/scripts/common
diff options
context:
space:
mode:
authorStefan Wintermeyer <stefan.wintermeyer@amooma.de>2013-02-26 10:48:43 +0100
committerStefan Wintermeyer <stefan.wintermeyer@amooma.de>2013-02-26 10:48:43 +0100
commitececfdf24075dd4e2794734a07187750b1b33e13 (patch)
tree63538e6f6135ce031da830da0ca6e14515e776e1 /misc/freeswitch/scripts/common
parentb144a7885610d605447c80f659643524a839db0c (diff)
parentad2121462a9ea9a776756a188779a9d504f078b7 (diff)
Merge branch 'develop' of github.com:amooma/GS5 into develop
Diffstat (limited to 'misc/freeswitch/scripts/common')
-rw-r--r--misc/freeswitch/scripts/common/group.lua2
1 files changed, 2 insertions, 0 deletions
diff --git a/misc/freeswitch/scripts/common/group.lua b/misc/freeswitch/scripts/common/group.lua
index 1a2d315..c4125bc 100644
--- a/misc/freeswitch/scripts/common/group.lua
+++ b/misc/freeswitch/scripts/common/group.lua
@@ -48,6 +48,7 @@ function Group.name_id_by_permission(self, member_id, member_type, permission)
WHERE `b`.`item_type` = ' .. self.database:escape(member_type, '"') .. ' \
AND `b`.`item_id` = ' .. member_id .. ' \
AND `a`.`permission` = ' .. self.database:escape(permission, '"') .. ' \
+ AND `c`.`active` IS TRUE \
GROUP BY `b`.`group_id` LIMIT ' .. MAX_GROUP_MEMBERSHIPS;
local group_names = {};
@@ -72,6 +73,7 @@ function Group.name_id_by_member(self, member_id, member_type)
JOIN `groups` `c` ON `c`.`id` = `b`.`group_id` \
WHERE `b`.`item_type` = ' .. self.database:escape(member_type, '"') .. ' \
AND `b`.`item_id` = ' .. member_id .. ' \
+ AND `c`.`active` IS TRUE \
GROUP BY `b`.`group_id` LIMIT ' .. MAX_GROUP_MEMBERSHIPS;
local group_names = {};