From 5fb50030b9801077eb131232dbafab694857214f Mon Sep 17 00:00:00 2001 From: weekface Date: Fri, 24 May 2019 11:42:11 +0800 Subject: [PATCH] don't send slack message if webhookURL is empty --- tests/slack/slack.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/slack/slack.go b/tests/slack/slack.go index 213e225c1c..57db503112 100644 --- a/tests/slack/slack.go +++ b/tests/slack/slack.go @@ -59,7 +59,7 @@ func (attachment *Attachment) AddField(field Field) *Attachment { func Send(webhookURL string, proxy string, payload Payload) error { if webhookURL == "" { - return fmt.Errorf("the webhookURL have not set") + return nil } body, err := json.Marshal(payload) if err != nil {