oops, moved DB test to real name

This commit is contained in:
2020-08-30 15:42:02 -04:00
parent 267c513f43
commit 16d7d3f7c0

View File

@@ -100,7 +100,7 @@ class ps4
function thumbnailurl($game_id)
{
$result = DB::queryFirstField(
"SELECT thumbnail FROM game_thumbnail2 WHERE game_id = %s",
"SELECT thumbnail FROM game_thumbnail WHERE game_id = %s",
$game_id
);
if ($result) {
@@ -121,13 +121,13 @@ class ps4
$actualurl = $this->thumbnailurl($gameid);
if ($actualurl == "images/no-thumbnail.png") {
$result = DB::query(
"INSERT INTO game_thumbnail2 (game_id, thumbnail) VALUES (%s, %?)",
"INSERT INTO game_thumbnail (game_id, thumbnail) VALUES (%s, %?)",
$gameid,
$imageContents
);
} else {
$result = DB::query(
"UPDATE game_thumbnail2 SET thumbnail = %? WHERE game_id = %s",
"UPDATE game_thumbnail SET thumbnail = %? WHERE game_id = %s",
$imageContents,
$gameid
);