Serve images from only one route enabling image previews in articles

This commit is contained in:
2024-10-30 03:24:29 +01:00
parent b4003c8216
commit b7d82f15e9
11 changed files with 41 additions and 59 deletions

View File

@@ -68,8 +68,7 @@ func main() {
mux.HandleFunc("GET /article/write", f.WriteArticle(config, db, store))
mux.HandleFunc("GET /atom/serve", c.ServeAtomFeed(config))
mux.HandleFunc("GET /hub", f.ShowHub(config, db, store))
mux.HandleFunc("GET /image/{img}", f.ServeImage(config, store))
mux.HandleFunc("GET /image/serve/{pic}", c.ServeImage(config))
mux.HandleFunc("GET /image/serve/{pic}", c.ServeImage(config, store))
mux.HandleFunc("GET /issue/this", f.ShowCurrentIssue(config, db, store))
mux.HandleFunc("GET /logout", f.Logout(config, store))
mux.HandleFunc("GET /pdf/get-list", c.ServePDFList(config))