summaryrefslogtreecommitdiff
path: root/notify.go
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2023-04-17 20:41:22 +0300
committerPaul Buetow <paul@buetow.org>2023-04-17 20:41:22 +0300
commite40e22f69470b987bfb2c39b4a18df67f497739d (patch)
tree73d03e14614b5b29ff07dec4ccb4cdad61234493 /notify.go
parentf7456fded178b85637c82255e9c3178817f5fa68 (diff)
can keep state
Diffstat (limited to 'notify.go')
-rw-r--r--notify.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/notify.go b/notify.go
index c31a242..3a295ba 100644
--- a/notify.go
+++ b/notify.go
@@ -26,3 +26,7 @@ func notify(config config, subject, body string) error {
return smtp.SendMail(config.SMTPServer, nil, config.EmailFrom,
[]string{config.EmailTo}, []byte(message))
}
+
+func notifyError(config config, err error) error {
+ return notify(config, fmt.Sprintf("GOGIOS: An error occured: %v", err), err.Error())
+}