diff options
author | Andrey Nering <andrey.nering@gmail.com> | 2016-06-29 12:11:00 -0300 |
---|---|---|
committer | 无闻 <u@gogs.io> | 2016-06-29 23:11:00 +0800 |
commit | 743d22669a49b743f1963dc579294a092c4980c1 (patch) | |
tree | dcb537495d87ae31e1b041d999a72c3dfc27b89a /routers/repo/pull.go | |
parent | 84841c8c4b257bd627fcc033112237d40e3a329a (diff) | |
download | gitea-743d22669a49b743f1963dc579294a092c4980c1.tar.gz gitea-743d22669a49b743f1963dc579294a092c4980c1.zip |
Re-work MAX_DIFF_LINES: supress diff per file, not the whole diff (#3174)
Diffstat (limited to 'routers/repo/pull.go')
-rw-r--r-- | routers/repo/pull.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/routers/repo/pull.go b/routers/repo/pull.go index 8ad4f3f8e4..922d64ef47 100644 --- a/routers/repo/pull.go +++ b/routers/repo/pull.go @@ -348,7 +348,8 @@ func ViewPullFiles(ctx *context.Context) { } diff, err := models.GetDiffRange(diffRepoPath, - startCommitID, endCommitID, setting.Git.MaxGitDiffLines) + startCommitID, endCommitID, setting.Git.MaxGitDiffLines, + setting.Git.MaxGitDiffLineCharacters, setting.Git.MaxGitDiffFiles) if err != nil { ctx.Handle(500, "GetDiffRange", err) return @@ -545,7 +546,8 @@ func PrepareCompareDiff( } diff, err := models.GetDiffRange(models.RepoPath(headUser.Name, headRepo.Name), - prInfo.MergeBase, headCommitID, setting.Git.MaxGitDiffLines) + prInfo.MergeBase, headCommitID, setting.Git.MaxGitDiffLines, + setting.Git.MaxGitDiffLineCharacters, setting.Git.MaxGitDiffFiles) if err != nil { ctx.Handle(500, "GetDiffRange", err) return false |