From 7f5551105a14be680378cdb57876fb073f75df55 Mon Sep 17 00:00:00 2001 From: Matt Baer Date: Mon, 24 Dec 2018 10:33:40 -0500 Subject: [PATCH] Fix metadata update redirect on single-user instances Fixes #50 --- posts.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/posts.go b/posts.go index e016ace..b321bd0 100644 --- a/posts.go +++ b/posts.go @@ -686,6 +686,10 @@ func existingPost(app *app, w http.ResponseWriter, r *http.Request) error { collPre = "" } redirect = collPre + "/" + pRes.Slug.String + "/edit/meta" + } else { + if app.cfg.App.SingleUser { + redirect = "/d" + redirect + } } w.Header().Set("Location", redirect) w.WriteHeader(http.StatusFound)