summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrey Nering <andrey.nering@gmail.com>2017-02-13 00:11:08 -0200
committerLunny Xiao <xiaolunwen@gmail.com>2017-02-13 10:11:08 +0800
commit05157808deddef8ff6f7cf959cd213ccb694b6fe (patch)
tree4b055d52ab5955deaad0f4f82967d87aa146720e
parent9b4f6c1c32c416e1cca0e29991c4f2481f26939d (diff)
downloadgitea-05157808deddef8ff6f7cf959cd213ccb694b6fe.tar.gz
gitea-05157808deddef8ff6f7cf959cd213ccb694b6fe.zip
Fix HighlightJS not working on compare diff page (#914)
-rw-r--r--routers/repo/commit.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/routers/repo/commit.go b/routers/repo/commit.go
index 37e57ac06f..7f4457c52b 100644
--- a/routers/repo/commit.go
+++ b/routers/repo/commit.go
@@ -292,5 +292,6 @@ func CompareDiff(ctx *context.Context) {
ctx.Data["SourcePath"] = setting.AppSubURL + "/" + path.Join(userName, repoName, "src", afterCommitID)
ctx.Data["BeforeSourcePath"] = setting.AppSubURL + "/" + path.Join(userName, repoName, "src", beforeCommitID)
ctx.Data["RawPath"] = setting.AppSubURL + "/" + path.Join(userName, repoName, "raw", afterCommitID)
+ ctx.Data["RequireHighlightJS"] = true
ctx.HTML(200, tplDiff)
}