From 196719fe24701a78de623ce108426bd22d9b77ac Mon Sep 17 00:00:00 2001 From: ston Date: Thu, 2 Jan 2025 17:44:47 +0800 Subject: [PATCH] fix: http(s)-file sub must have tag --- common/subscription/subscription.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/common/subscription/subscription.go b/common/subscription/subscription.go index 9fde1496a..17ede6d8e 100644 --- a/common/subscription/subscription.go +++ b/common/subscription/subscription.go @@ -165,6 +165,9 @@ func ResolveSubscription(log *logrus.Logger, client *http.Client, configDir stri } goto resolve case "http-file", "https-file": + if len(tag) == 0 { + return "", nil, fmt.Errorf("tag is required for http-file/https-file subscription") + } persistToFile = true subscription = strings.Replace(subscription, "-file", "", 1) break