aboutsummaryrefslogtreecommitdiff
path: root/lib/render.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/render.js')
-rw-r--r--lib/render.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/render.js b/lib/render.js
index 21cdbda..d28f4b4 100644
--- a/lib/render.js
+++ b/lib/render.js
@@ -304,3 +304,11 @@ Render.prototype.renderFeeds = function (opts) {
self.renderMsg(msg, opts, cb)
}, 4)
}
+
+Render.prototype.gitCommitBody = function (body) {
+ if (!body) return ''
+ var isMarkdown = !/^# Conflicts:$/m.test(body)
+ return isMarkdown
+ ? h('div', {innerHTML: this.markdown('\n' + body)})
+ : h('pre', this.linkify('\n' + body))
+}