Merge branch 'master' into feature/goimports
This commit is contained in:
commit
f36544f98d
5 changed files with 8 additions and 27 deletions
|
@ -177,11 +177,6 @@ func Diff(ctx *context.Context) {
|
|||
}
|
||||
}
|
||||
|
||||
setEditorconfigIfExists(ctx)
|
||||
if ctx.Written() {
|
||||
return
|
||||
}
|
||||
|
||||
ctx.Data["CommitID"] = commitID
|
||||
ctx.Data["IsSplitStyle"] = ctx.Query("style") == "split"
|
||||
ctx.Data["Username"] = userName
|
||||
|
|
|
@ -8,7 +8,7 @@ import (
|
|||
git "github.com/gogits/git-module"
|
||||
)
|
||||
|
||||
func setEditorconfigIfExists(ctx *context.Context) {
|
||||
func SetEditorconfigIfExists(ctx *context.Context) {
|
||||
ec, err := ctx.Repo.GetEditorconfig()
|
||||
|
||||
if err != nil && !git.IsErrNotExist(err) {
|
||||
|
|
|
@ -366,11 +366,6 @@ func ViewPullFiles(ctx *context.Context) {
|
|||
return
|
||||
}
|
||||
|
||||
setEditorconfigIfExists(ctx)
|
||||
if ctx.Written() {
|
||||
return
|
||||
}
|
||||
|
||||
headTarget := path.Join(pull.HeadUserName, pull.HeadRepo.Name)
|
||||
ctx.Data["IsSplitStyle"] = ctx.Query("style") == "split"
|
||||
ctx.Data["Username"] = pull.HeadUserName
|
||||
|
@ -623,11 +618,6 @@ func CompareAndPullRequest(ctx *context.Context) {
|
|||
}
|
||||
}
|
||||
|
||||
setEditorconfigIfExists(ctx)
|
||||
if ctx.Written() {
|
||||
return
|
||||
}
|
||||
|
||||
ctx.HTML(200, COMPARE_PULL)
|
||||
}
|
||||
|
||||
|
|
|
@ -243,11 +243,6 @@ func Home(ctx *context.Context) {
|
|||
return
|
||||
}
|
||||
|
||||
setEditorconfigIfExists(ctx)
|
||||
if ctx.Written() {
|
||||
return
|
||||
}
|
||||
|
||||
var treeNames []string
|
||||
paths := make([]string, 0, 5)
|
||||
if len(ctx.Repo.TreePath) > 0 {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue