From 64a40962ccfd34ba4a5a64e623e59d00a32318c0 Mon Sep 17 00:00:00 2001 From: Lunny Xiao Date: Tue, 10 May 2022 20:41:37 +0800 Subject: Fix new release from tags list UI (#19670) --- routers/web/repo/release.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'routers/web/repo') diff --git a/routers/web/repo/release.go b/routers/web/repo/release.go index 5f894ae501..ebc6500802 100644 --- a/routers/web/repo/release.go +++ b/routers/web/repo/release.go @@ -279,7 +279,9 @@ func NewRelease(ctx *context.Context) { } ctx.Data["tag_name"] = rel.TagName - ctx.Data["tag_target"] = rel.Target + if rel.Target != "" { + ctx.Data["tag_target"] = rel.Target + } ctx.Data["title"] = rel.Title ctx.Data["content"] = rel.Note ctx.Data["attachments"] = rel.Attachments -- cgit v1.2.3