aboutsummaryrefslogtreecommitdiff
path: root/lib/serve.js
diff options
context:
space:
mode:
authorcel <cel@f/6sQ6d2CMxRUhLpspgGIulDxDCwYD7DzFzPNr7u5AU=.ed25519>2018-01-09 22:02:17 -1000
committercel <cel@f/6sQ6d2CMxRUhLpspgGIulDxDCwYD7DzFzPNr7u5AU=.ed25519>2018-01-09 22:02:17 -1000
commit7052ddce7a33724467c076dff4217c73001d4a8c (patch)
tree4a8f402ce9b3d8e52f5e133001859cef35d70eb4 /lib/serve.js
parentafc315b47e13e5a98eb37b9b56a0d36571d1c4a9 (diff)
downloadpatchfoo-7052ddce7a33724467c076dff4217c73001d4a8c.tar.gz
patchfoo-7052ddce7a33724467c076dff4217c73001d4a8c.zip
Use correct message ids in commit file diff links
Diffstat (limited to 'lib/serve.js')
-rw-r--r--lib/serve.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/serve.js b/lib/serve.js
index 5ba0004..793ad84 100644
--- a/lib/serve.js
+++ b/lib/serve.js
@@ -1799,6 +1799,7 @@ Serve.prototype.gitCommit = function (rev) {
ph('table', pull(
self.app.git.readCommitChanges(commit),
pull.map(function (file) {
+ var msg = file.msg || obj.msg
return ph('tr', [
ph('td', ph('code', u.escapeHTML(file.name))),
ph('td', file.deleted ? 'deleted'
@@ -1806,13 +1807,13 @@ Serve.prototype.gitCommit = function (rev) {
ph('a', {href:
self.app.render.toUrl('/git/blob/'
+ (file.hash[1] || file.hash[0])
- + '?msg=' + encodeURIComponent(obj.msg.key))
+ + '?msg=' + encodeURIComponent(msg.key))
}, 'created')
: file.hash ?
ph('a', {href:
self.app.render.toUrl('/git/diff/'
+ file.hash[0] + '..' + file.hash[1]
- + '?msg=' + encodeURIComponent(obj.msg.key))
+ + '?msg=' + encodeURIComponent(msg.key))
+ '&commit=' + rev
+ '&path=' + encodeURIComponent(file.name)
}, 'changed')