diff options
author | Unknwon <u@gogs.io> | 2016-08-30 02:08:38 -0700 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2016-08-30 02:08:38 -0700 |
commit | 780cc2d11093e048e41f2d6da9d76f6c6ac4a5e2 (patch) | |
tree | 1657d9fecdcf70d4e0067724344f531d608efb71 /routers/repo/editor.go | |
parent | 2a13f682e0fa039a610e7817495d87685f9632f2 (diff) | |
download | gitea-780cc2d11093e048e41f2d6da9d76f6c6ac4a5e2.tar.gz gitea-780cc2d11093e048e41f2d6da9d76f6c6ac4a5e2.zip |
router/repo: code refactoring
Diffstat (limited to 'routers/repo/editor.go')
-rw-r--r-- | routers/repo/editor.go | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/routers/repo/editor.go b/routers/repo/editor.go index 81f95956a3..465de00214 100644 --- a/routers/repo/editor.go +++ b/routers/repo/editor.go @@ -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 } |