aboutsummaryrefslogtreecommitdiffstats
path: root/include/ws_functions/pwg.users.php
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--include/ws_functions/pwg.users.php10
1 files changed, 8 insertions, 2 deletions
diff --git a/include/ws_functions/pwg.users.php b/include/ws_functions/pwg.users.php
index cbc988343..c63284d3e 100644
--- a/include/ws_functions/pwg.users.php
+++ b/include/ws_functions/pwg.users.php
@@ -167,7 +167,13 @@ SELECT DISTINCT ';
OFFSET '. ($params['per_page']*$params['page']) .'
;';
- $users = hash_from_query($query, 'id');
+ $users = array();
+ $result = pwg_query($query);
+ while ($row = pwg_db_fetch_assoc($result))
+ {
+ $row['id'] = intval($row['id']);
+ $users[ $row['id'] ] = $row;
+ }
if (count($users) > 0)
{
@@ -182,7 +188,7 @@ SELECT user_id, group_id
while ($row = pwg_db_fetch_assoc($result))
{
- $users[ $row['user_id'] ]['groups'][] = $row['group_id'];
+ $users[ $row['user_id'] ]['groups'][] = intval($row['group_id']);
}
}