Fix metadata update redirect on single-user instances

Fixes #50
embedded-data
Matt Baer 6 years ago
parent 1439c8c359
commit 7f5551105a
  1. 4
      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)

Loading…
Cancel
Save