diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2016-11-25 14:23:48 +0800 |
---|---|---|
committer | Lunny Xiao <xiaolunwen@gmail.com> | 2016-11-25 14:23:48 +0800 |
commit | 229ec927b953cf80b5eecb03d412a9634b83a25a (patch) | |
tree | cddd09bed1ba2d98a010173d102dde56e94d0801 /routers/repo | |
parent | 6a28909f40ad1ff20d325d9be4ada87e5b75ce53 (diff) | |
download | gitea-229ec927b953cf80b5eecb03d412a9634b83a25a.tar.gz gitea-229ec927b953cf80b5eecb03d412a9634b83a25a.zip |
Golint fixed for modules/template
Diffstat (limited to 'routers/repo')
-rw-r--r-- | routers/repo/editor.go | 2 | ||||
-rw-r--r-- | routers/repo/view.go | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/routers/repo/editor.go b/routers/repo/editor.go index d0d528e250..92a41f0147 100644 --- a/routers/repo/editor.go +++ b/routers/repo/editor.go @@ -74,7 +74,7 @@ func editFile(ctx *context.Context, isNewFile bool) { d, _ := ioutil.ReadAll(dataRc) buf = append(buf, d...) - if err, content := template.ToUTF8WithErr(buf); err != nil { + if content, err := template.ToUTF8WithErr(buf); err != nil { if err != nil { log.Error(4, "ToUTF8WithErr: %v", err) } diff --git a/routers/repo/view.go b/routers/repo/view.go index 7303e44126..3ef3716f27 100644 --- a/routers/repo/view.go +++ b/routers/repo/view.go @@ -164,7 +164,7 @@ func renderFile(ctx *context.Context, entry *git.TreeEntry, treeLink, rawLink st } else { // Building code view blocks with line number on server side. var fileContent string - if err, content := template.ToUTF8WithErr(buf); err != nil { + if content, err := template.ToUTF8WithErr(buf); err != nil { if err != nil { log.Error(4, "ToUTF8WithErr: %s", err) } |