From 79464b08ec76734f22af365a08d6f8201ec9fb5c Mon Sep 17 00:00:00 2001 From: Roberto Hidalgo Date: Sun, 16 Apr 2023 16:19:40 -0600 Subject: [PATCH] =?UTF-8?q?fix=20config=20parsing=20=F0=9F=A4=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- internal/push/push.go | 6 +++--- internal/server/server.go | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/internal/push/push.go b/internal/push/push.go index 9a63b62..915f00b 100644 --- a/internal/push/push.go +++ b/internal/push/push.go @@ -6,12 +6,12 @@ import ( ) type VAPIDKey struct { - Private string - Public string + Private string `yaml:"private"` + Public string `yaml:"public"` } type Config struct { - Key *VAPIDKey + Key *VAPIDKey `yaml:"key"` } type Notifier struct { diff --git a/internal/server/server.go b/internal/server/server.go index f4a71d7..3122247 100644 --- a/internal/server/server.go +++ b/internal/server/server.go @@ -140,7 +140,7 @@ func notifyAdmins(message string) { logrus.Errorf("could not fetch subscriptions: %s", err) } - logrus.Infof("notifying %v admins", subs[0].AsWebPush()) + logrus.Infof("notifying %v admins", len(subs)) for _, sub := range subs { err := push.Notify(message, sub)