From fde01c6f84df0c3e9c9f1181995c71145e660d56 Mon Sep 17 00:00:00 2001 From: Howl Date: Thu, 26 May 2016 21:13:36 +0200 Subject: [PATCH] Don't print 0pp scores on std on user/scores/best --- app/v1/user_scores.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/v1/user_scores.go b/app/v1/user_scores.go index ff8a609..bb6e2c9 100644 --- a/app/v1/user_scores.go +++ b/app/v1/user_scores.go @@ -63,6 +63,11 @@ func UserScoresBestGET(md common.MethodData) common.CodeMessager { if cm != nil { return *cm } + mc := genModeClause(md) + // Do not print 0pp scores on std + if getMode(md.C.Query("mode")) == "std" { + mc += " AND scores.pp > 0" + } return scoresPuts(md, fmt.Sprintf( `WHERE scores.completed = '3'