Explorar o código

alerting: only log when screenshot been uploaded

bergquist %!s(int64=7) %!d(string=hai) anos
pai
achega
c4292b43f5
Modificáronse 1 ficheiros con 4 adicións e 1 borrados
  1. 4 1
      pkg/services/alerting/notifier.go

+ 4 - 1
pkg/services/alerting/notifier.go

@@ -104,7 +104,10 @@ func (n *notificationService) uploadImage(context *EvalContext) (err error) {
 		return err
 	}
 
-	n.log.Info("uploaded", "url", context.ImagePublicUrl)
+	if context.ImagePublicUrl != "" {
+		n.log.Info("uploaded screenshot of alert to external image store", "url", context.ImagePublicUrl)
+	}
+
 	return nil
 }