From fa5095261afc343575f734cfa1d705948a7d22f4 Mon Sep 17 00:00:00 2001 From: kumfo Date: Wed, 4 Sep 2024 17:33:50 +0800 Subject: [PATCH] fix(badge): fixed badge description translation --- internal/service/badge/badge_service.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/internal/service/badge/badge_service.go b/internal/service/badge/badge_service.go index 029130adc..0ab538a3b 100644 --- a/internal/service/badge/badge_service.go +++ b/internal/service/badge/badge_service.go @@ -208,8 +208,9 @@ func (b *BadgeService) ListPaged(ctx context.Context, req *schema.GetBadgeListPa var baseURL = "" if siteErr != nil { baseURL = "" + } else { + baseURL = general.SiteUrl } - baseURL = general.SiteUrl for i, badge := range badges { resp[i] = &schema.GetBadgeListPagedResp{ @@ -268,8 +269,9 @@ func (b *BadgeService) GetBadgeInfo(ctx *gin.Context, id string, userID string) var baseURL = "" if siteErr != nil { baseURL = "" + } else { + baseURL = general.SiteUrl } - baseURL = general.SiteUrl info = &schema.GetBadgeInfoResp{ ID: uid.EnShortID(badge.ID),