summaryrefslogtreecommitdiffstats
path: root/routers/repo/pull.go
diff options
context:
space:
mode:
Diffstat (limited to 'routers/repo/pull.go')
-rw-r--r--routers/repo/pull.go17
1 files changed, 16 insertions, 1 deletions
diff --git a/routers/repo/pull.go b/routers/repo/pull.go
index 1d7747450b..e6592e1f57 100644
--- a/routers/repo/pull.go
+++ b/routers/repo/pull.go
@@ -456,6 +456,12 @@ func ViewPullFiles(ctx *context.Context) {
ctx.ServerError("GetDiffRange", err)
return
}
+
+ if err = diff.LoadComments(issue, ctx.User); err != nil {
+ ctx.ServerError("LoadComments", err)
+ return
+ }
+
ctx.Data["Diff"] = diff
ctx.Data["DiffNotAvailable"] = diff.NumFiles() == 0
@@ -470,7 +476,16 @@ func ViewPullFiles(ctx *context.Context) {
ctx.Data["BeforeSourcePath"] = setting.AppSubURL + "/" + path.Join(headTarget, "src", "commit", startCommitID)
ctx.Data["RawPath"] = setting.AppSubURL + "/" + path.Join(headTarget, "raw", "commit", endCommitID)
ctx.Data["RequireHighlightJS"] = true
-
+ ctx.Data["RequireTribute"] = true
+ if ctx.Data["Assignees"], err = ctx.Repo.Repository.GetAssignees(); err != nil {
+ ctx.ServerError("GetAssignees", err)
+ return
+ }
+ ctx.Data["CurrentReview"], err = models.GetCurrentReview(ctx.User, issue)
+ if err != nil && !models.IsErrReviewNotExist(err) {
+ ctx.ServerError("GetCurrentReview", err)
+ return
+ }
ctx.HTML(200, tplPullFiles)
}