From 38008a54515a7492602b1a2b0bd9ee77af30cb1b Mon Sep 17 00:00:00 2001 From: Nyo Date: Wed, 20 Jul 2016 10:49:29 +0200 Subject: [PATCH] Fix error on scores handlers --- app/v1/beatmap.go | 2 +- app/v1/user_scores.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/v1/beatmap.go b/app/v1/beatmap.go index d84cae5..9896813 100644 --- a/app/v1/beatmap.go +++ b/app/v1/beatmap.go @@ -78,7 +78,7 @@ func BeatmapSetStatusPOST(md common.MethodData) common.CodeMessager { } } - md.DB.Exec(`UPDATE beatmaps + md.DB.Exec(`UPDATE beatmaps SET ranked = ?, ranked_status_freezed = ? WHERE beatmapset_id = ?`, req.RankedStatus, req.Frozen, param) diff --git a/app/v1/user_scores.go b/app/v1/user_scores.go index f6c7b1d..0df05e7 100644 --- a/app/v1/user_scores.go +++ b/app/v1/user_scores.go @@ -53,8 +53,8 @@ SELECT beatmaps.max_combo, beatmaps.hit_length, beatmaps.ranked, beatmaps.ranked_status_freezed, beatmaps.latest_update FROM scores -LEFT JOIN beatmaps ON beatmaps.beatmap_md5 = scores.beatmap_md5 -LEFT JOIN users ON users.id = scores.userid +INNER JOIN beatmaps ON beatmaps.beatmap_md5 = scores.beatmap_md5 +INNER JOIN users ON users.id = scores.userid ` // UserScoresBestGET retrieves the best scores of an user, sorted by PP if