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

Run gofmt

This commit is contained in:
Umar Getagazov 2021-09-29 21:56:17 +07:00
parent 6636fc95a7
commit 33650e965c
6 changed files with 6 additions and 6 deletions

View File

@ -1,11 +1,11 @@
package shroom
import (
"bytes"
"errors"
"fmt"
"io"
"log"
"bytes"
"mime/multipart"
"os"
"path/filepath"

View File

@ -92,7 +92,7 @@ func handlerLogout(w http.ResponseWriter, rq *http.Request) {
var (
u = user.FromRequest(rq)
can = u != nil
lc = l18n.FromRequest(rq)
lc = l18n.FromRequest(rq)
)
w.Header().Set("Content-Type", "text/html;charset=utf-8")
if can {

View File

@ -55,7 +55,7 @@ func handlerRecentChanges(w http.ResponseWriter, rq *http.Request) {
var lc = l18n.FromRequest(rq)
util.HTTP200Page(w, views.BaseHTML(
lc.GetPlural("ui.recent_title", n),
views.RecentChangesHTML(n, lc),
views.RecentChangesHTML(n, lc),
lc,
user.FromRequest(rq)))
}

View File

@ -6,10 +6,10 @@ import (
"github.com/gorilla/mux"
"github.com/bouncepaw/mycorrhiza/l18n"
"github.com/bouncepaw/mycorrhiza/shroom"
"github.com/bouncepaw/mycorrhiza/user"
"github.com/bouncepaw/mycorrhiza/util"
"github.com/bouncepaw/mycorrhiza/l18n"
"github.com/bouncepaw/mycorrhiza/views"
)

View File

@ -154,7 +154,7 @@ func handlerAbout(w http.ResponseWriter, rq *http.Request) {
w.Header().Set("Content-Type", "text/html;charset=utf-8")
w.WriteHeader(http.StatusOK)
var (
lc = l18n.FromRequest(rq)
lc = l18n.FromRequest(rq)
title = lc.Get("ui.about_title", &l18n.Replacements{"name": cfg.WikiName})
)
_, err := io.WriteString(w, views.BaseHTML(title, views.AboutHTML(lc), lc, user.FromRequest(rq)))

View File

@ -38,7 +38,7 @@ func httpErr(w http.ResponseWriter, lc *l18n.Localizer, status int, name, title,
name,
lc.Get("ui.error_go_back"),
),
lc,
lc,
user.EmptyUser(),
),
)