From ea050a2deccb6e0dd88accc4c3a5078cd3a4297d Mon Sep 17 00:00:00 2001 From: shenjiachi Date: Wed, 11 Dec 2024 20:30:04 +0800 Subject: [PATCH] update --- app/svc/svc_points_center.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/svc/svc_points_center.go b/app/svc/svc_points_center.go index 6ca2cea..5c8c603 100644 --- a/app/svc/svc_points_center.go +++ b/app/svc/svc_points_center.go @@ -78,7 +78,11 @@ func GetEggPointRecordBase(now time.Time, uid int64, page int, limit int) ([]md. results = append(results, doc) } } - nowScore = utils.Float64ToStr(results[0].ScoreValue) + if len(results) > 0 { + nowScore = utils.Float64ToStr(results[0].ScoreValue) + } else { + nowScore = "60" + } } else { nowScore = "60" }