viewgit/inc/functions.php:22 Function utf8_encode() is deprecated [8192]

Attempt to speed up queries in manageaccount activity 3, a=chris

Chris Pollett [2020-06-23 23:Jun:rd]
Attempt to speed up queries in manageaccount activity 3, a=chris
Filename
src/models/GroupModel.php
diff --git a/src/models/GroupModel.php b/src/models/GroupModel.php
index 1b7e5abd6..fe9abf374 100644
--- a/src/models/GroupModel.php
+++ b/src/models/GroupModel.php
@@ -1132,7 +1132,8 @@ class GroupModel extends Model implements MediaConstants
             GI.UPS AS UPS, GI.DOWNS AS DOWNS, G.VOTE_ACCESS AS VOTE_ACCESS
             FROM GROUP_ITEM GI, GROUPS G, USERS P
             WHERE GI.GROUP_ID = ? AND GI.GROUP_ID=G.GROUP_ID AND
-            GI.USER_ID = P.USER_ID AND GI.PUBDATE = ? LIMIT 0 , 1";
+            GI.USER_ID = P.USER_ID AND GI.PUBDATE = ? ".
+            $db->limitOffset(0, 1);
         $result = $db->execute($sql, [$group_id, $row['PUBDATE']]);
         if (empty($result)) {
             return "";
ViewGit