1
0
mirror of https://github.com/osmarks/mycorrhiza.git synced 2025-06-26 07:02:49 +00:00

Fix the error when previewing

This commit is contained in:
bouncepaw 2021-02-20 21:21:10 +05:00
parent 8cdea2d7ba
commit c726a8b307

View File

@ -179,13 +179,12 @@ func handlerUploadText(w http.ResponseWriter, rq *http.Request) {
if action != "Preview" { if action != "Preview" {
hop, errtitle = shroom.UploadText(h, []byte(textData), u) hop, errtitle = shroom.UploadText(h, []byte(textData), u)
} if hop.HasErrors() {
HttpErr(w, http.StatusForbidden, hyphaName,
if hop.HasErrors() { errtitle,
HttpErr(w, http.StatusForbidden, hyphaName, hop.FirstErrorText())
errtitle, return
hop.FirstErrorText()) }
return
} }
if action == "Preview" { if action == "Preview" {