Skip to content
Snippets Groups Projects
Commit 121d5286 authored by Arthur Schiwon's avatar Arthur Schiwon
Browse files

return int, not string

parent 5dab7620
No related branches found
No related tags found
No related merge requests found
......@@ -221,7 +221,11 @@ class OC_Group_Database extends OC_Group_Backend {
public function countUsersInGroup($gid, $search = '') {
$stmt = OC_DB::prepare('SELECT COUNT(`uid`) AS `count` FROM `*PREFIX*group_user` WHERE `gid` = ? AND `uid` LIKE ?');
$result = $stmt->execute(array($gid, '%' . $search . '%'));
return $result->fetchOne();
$count = $result->fetchOne();
if($count !== false) {
$count = intval($count);
}
return $count;
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment