router/repo: code refactoring

This commit is contained in:
Unknwon committed 2016-08-30 02:08:38 -07:00
1 parent 2a13f682e0
commit 780cc2d110
13 files changed
+253 -261

No files matched your search

+1 -2
View File
@@ -72,8 +72,7 @@ func editFile(ctx *context.Context, isNewFile bool) {
}
// Only text file are editable online.
_, isTextFile := base.IsTextFile(buf)
if !isTextFile {
if !base.IsTextFile(buf) {
ctx.Handle(404, "", nil)
return
}