removes error2 logger

This commit is contained in:
bergquist
2019-01-15 11:49:18 +01:00
parent 1c0a385df1
commit 1b6203e430
4 changed files with 13 additions and 17 deletions
+1 -1
View File
@@ -130,7 +130,7 @@ func (this *TelegramNotifier) buildMessageInlineImage(evalContext *alerting.Eval
defer func() {
err := imageFile.Close()
if err != nil {
log.Error2("Could not close Telegram inline image.", "err", err)
this.log.Error("Could not close Telegram inline image.", "err", err)
}
}()
+5 -2
View File
@@ -18,9 +18,12 @@ type NotificationTestCommand struct {
Settings *simplejson.Json
}
var (
logger = log.New("alerting.testnotification")
)
func init() {
bus.AddHandler("alerting", handleNotificationTestCommand)
}
func handleNotificationTestCommand(cmd *NotificationTestCommand) error {
@@ -35,7 +38,7 @@ func handleNotificationTestCommand(cmd *NotificationTestCommand) error {
notifiers, err := InitNotifier(model)
if err != nil {
log.Error2("Failed to create notifier", "error", err.Error())
logger.Error("Failed to create notifier", "error", err.Error())
return err
}