aboutsummaryrefslogtreecommitdiffstats
path: root/mod/acl.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2013-12-22 18:37:39 -0800
committerfriendica <info@friendica.com>2013-12-22 18:37:39 -0800
commit1a42580ad44f768ba8d4eb0669f3b8be03670e04 (patch)
treee40948063cea08c8c0ea4ece8efbcc6bef6464d8 /mod/acl.php
parenteff38538eeaa3af0774c77d26c5b00dd79cb9e8c (diff)
downloadvolse-hubzilla-1a42580ad44f768ba8d4eb0669f3b8be03670e04.tar.gz
volse-hubzilla-1a42580ad44f768ba8d4eb0669f3b8be03670e04.tar.bz2
volse-hubzilla-1a42580ad44f768ba8d4eb0669f3b8be03670e04.zip
remove a couple of mysql reserved words from being used as table or row names. For this round we're getting 'group' and 'desc'. Warning: potentially destabilising as this touches a lot of code.
Diffstat (limited to 'mod/acl.php')
-rw-r--r--mod/acl.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/mod/acl.php b/mod/acl.php
index bd19c4bb7..c9a4d417f 100644
--- a/mod/acl.php
+++ b/mod/acl.php
@@ -39,7 +39,7 @@ function acl_init(&$a){
// count groups and contacts
if ($type=='' || $type=='g'){
- $r = q("SELECT COUNT(`id`) AS g FROM `group` WHERE `deleted` = 0 AND `uid` = %d $sql_extra",
+ $r = q("SELECT COUNT(`id`) AS g FROM `groups` WHERE `deleted` = 0 AND `uid` = %d $sql_extra",
intval(local_user())
);
$group_count = (int)$r[0]['g'];
@@ -94,14 +94,14 @@ function acl_init(&$a){
if ($type=='' || $type=='g'){
- $r = q("SELECT `group`.`id`, `group`.`hash`, `group`.`name`,
+ $r = q("SELECT `groups`.`id`, `groups`.`hash`, `groups`.`name`,
GROUP_CONCAT(DISTINCT `group_member`.`xchan` SEPARATOR ',') as uids
- FROM `group`,`group_member`
- WHERE `group`.`deleted` = 0 AND `group`.`uid` = %d
- AND `group_member`.`gid`=`group`.`id`
+ FROM `groups`,`group_member`
+ WHERE `groups`.`deleted` = 0 AND `groups`.`uid` = %d
+ AND `group_member`.`gid`=`groups`.`id`
$sql_extra
- GROUP BY `group`.`id`
- ORDER BY `group`.`name`
+ GROUP BY `groups`.`id`
+ ORDER BY `groups`.`name`
LIMIT %d,%d",
intval(local_user()),
intval($start),