watchyourlan/internal/notify/shoutrrr.go
2022-12-28 22:34:40 +07:00

16 lines
296 B
Go

package notify
import (
"github.com/containrrr/shoutrrr"
"log"
)
// Shoutrrr - send message with shoutrrr
func Shoutrrr(message string, url string) {
if url != "" {
err := shoutrrr.Send(url, message)
if err != nil {
log.Println("ERROR: Notification failed (shoutrrr):", err)
}
}
}