diff --git a/routers/web/repo/compare.go b/routers/web/repo/compare.go
index 989691a572..a206f8deb6 100644
--- a/routers/web/repo/compare.go
+++ b/routers/web/repo/compare.go
@@ -750,6 +750,7 @@ func CompareDiff(ctx *context.Context) {
return
}
+ ctx.Data["PageIsCompareDiff"] = true
ctx.Data["PullRequestWorkInProgressPrefixes"] = setting.Repository.PullRequest.WorkInProgressPrefixes
ctx.Data["DirectComparison"] = ci.DirectComparison
ctx.Data["OtherCompareSeparator"] = ".."
diff --git a/templates/repo/diff/options_dropdown.tmpl b/templates/repo/diff/options_dropdown.tmpl
index 8d08e7ad46..a8a6c2ac10 100644
--- a/templates/repo/diff/options_dropdown.tmpl
+++ b/templates/repo/diff/options_dropdown.tmpl
@@ -10,6 +10,9 @@
{{else if .Commit.ID.String}}
{{ctx.Locale.Tr "repo.diff.download_patch"}}
{{ctx.Locale.Tr "repo.diff.download_diff"}}
+ {{else if $.PageIsCompareDiff }}
+ {{ctx.Locale.Tr "repo.diff.download_patch"}}
+ {{ctx.Locale.Tr "repo.diff.download_diff"}}
{{end}}
{{ctx.Locale.Tr "repo.pulls.expand_files"}}
{{ctx.Locale.Tr "repo.pulls.collapse_files"}}