From 093cc0cb567dd4a3cc173f705d1ecd6d17176963 Mon Sep 17 00:00:00 2001 From: Bill Thiede Date: Sat, 25 Feb 2023 10:45:55 -0800 Subject: [PATCH] Change info log to error and remove noisy log --- cmd/unread/unread.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/cmd/unread/unread.go b/cmd/unread/unread.go index fb4654c..ea8458b 100644 --- a/cmd/unread/unread.go +++ b/cmd/unread/unread.go @@ -15,7 +15,7 @@ import ( ) var ( - root = flag.String("root", filepath.Join(os.Getenv("HOME"), "Maildir/"), + root = flag.String("root", filepath.Join(os.Getenv("HOME"), "Maildir"), "root directory to watch") poll = flag.Duration("poll", time.Second*time.Duration(10), "poll interval between new file check") @@ -128,7 +128,7 @@ func (mc *mailCounter) ServeHTTP(w http.ResponseWriter, r *http.Request) { enc := json.NewEncoder(w) err := enc.Encode(c) if err != nil { - glog.Infoln("Error printing JSON:", err) + glog.Errorln("Error printing JSON:", err) } } @@ -195,7 +195,6 @@ func (mc *mailCounter) fillNeedUpdate() error { // glog.Infoln("END fillNeedUpdate", mc.needUpdate) // }() return filepath.Walk(mc.root, func(path string, info os.FileInfo, err error) error { - glog.Infof("path %s", path) if err != nil { return err }