diff --git a/main.go b/main.go index 7592378..35cb16c 100644 --- a/main.go +++ b/main.go @@ -98,10 +98,13 @@ func main() { // TODO: Proper error handling count, err := countMailsInMailbox(mailbox) if err != nil { + log.Printf("Cound not load mailbox data: %v", err) http.Error(w, fmt.Sprintf("Cound not load mailbox data: %v", err), http.StatusInternalServerError) return } + log.Printf("Loaded mail count for mailbox %s: %d", mailbox, count) + probeCountGauge.Set(float64(count)) h := promhttp.HandlerFor(registry, promhttp.HandlerOpts{})