File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -335,7 +335,7 @@ public static function listFromGame(int $time = 0)
335335 //return $sth->fetchAll(PDO::FETCH_ASSOC);
336336
337337 $ results = [];
338- foreach ($ sth ->fetchAll (PDO ::FETCH_ASSOC ) as $ entry ) {
338+ while ($ entry = $ sth ->fetch (PDO ::FETCH_ASSOC )) {
339339 $ json = json_decode ($ entry ['data ' ], true );
340340 $ data_stripped = json_encode (['game_code ' => $ json ['game_code ' ] ?? null ]);
341341
Original file line number Diff line number Diff line change @@ -327,7 +327,7 @@ public static function listFromGame(int $time = 0)
327327 //return $sth->fetchAll(PDO::FETCH_ASSOC);
328328
329329 $ results = [];
330- foreach ($ sth ->fetchAll (PDO ::FETCH_ASSOC ) as $ entry ) {
330+ while ($ entry = $ sth ->fetch (PDO ::FETCH_ASSOC )) {
331331 $ json = json_decode ($ entry ['data ' ], true );
332332 $ data_stripped = json_encode (['game_code ' => $ json ['game_code ' ] ?? null ]);
333333
You can’t perform that action at this time.
0 commit comments