From 4283ceecfcfbb5dcfb7481d1b9bf74efcd284a2d Mon Sep 17 00:00:00 2001 From: Mechiel Lukkien Date: Sun, 3 Sep 2023 15:17:09 +0200 Subject: [PATCH] fix serving static webmail files in development mode due to a missing return, the content was served again. this path doesn't happen on release binaries, only during local development, where there is a local file that can be served. --- webmail/webmail.go | 1 + 1 file changed, 1 insertion(+) diff --git a/webmail/webmail.go b/webmail/webmail.go index 5279401..9eed01c 100644 --- a/webmail/webmail.go +++ b/webmail/webmail.go @@ -311,6 +311,7 @@ func serveContentFallback(log *mlog.Log, w http.ResponseWriter, r *http.Request, st, err := f.Stat() if err == nil { http.ServeContent(w, r, "", st.ModTime(), f) + return } } http.ServeContent(w, r, "", fallbackMtime(log), bytes.NewReader(fallback))