File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -3139,7 +3139,9 @@ public function pruneOutdatedSyncTokens(int $keep = 10_000): int {
31393139 $ query ->select ($ query ->func ()->max ('id ' ))
31403140 ->from ('calendarchanges ' );
31413141
3142- $ maxId = $ query ->executeQuery ()->fetchOne ();
3142+ $ result = $ query ->executeQuery ();
3143+ $ maxId = (int ) $ result ->fetchOne ();
3144+ $ result ->closeCursor ();
31433145 if (!$ maxId || $ maxId < $ keep ) {
31443146 return 0 ;
31453147 }
Original file line number Diff line number Diff line change @@ -1404,7 +1404,9 @@ public function pruneOutdatedSyncTokens(int $keep = 10_000): int {
14041404 $ query ->select ($ query ->func ()->max ('id ' ))
14051405 ->from ('addressbookchanges ' );
14061406
1407- $ maxId = $ query ->executeQuery ()->fetchOne ();
1407+ $ result = $ query ->executeQuery ();
1408+ $ maxId = (int ) $ result ->fetchOne ();
1409+ $ result ->closeCursor ();
14081410 if (!$ maxId || $ maxId < $ keep ) {
14091411 return 0 ;
14101412 }
You can’t perform that action at this time.
0 commit comments