aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcel <cel@lOUVT+Phkvai9a/cCS/RKo+S9hnPAQdVixms/7ldpPA=.ed25519>2020-11-27 12:22:17 -0500
committercel <cel@lOUVT+Phkvai9a/cCS/RKo+S9hnPAQdVixms/7ldpPA=.ed25519>2020-11-27 12:22:17 -0500
commit8c041619fc4e7903ba9c99b7bd290c0719a21972 (patch)
treef5f17af5da53b04310f9922cacbc3eeaaa5fdc16
parent567a75309f69d495ff55a1dc6b43a4774c69fe31 (diff)
downloadpatchfoo-8c041619fc4e7903ba9c99b7bd290c0719a21972.tar.gz
patchfoo-8c041619fc4e7903ba9c99b7bd290c0719a21972.zip
Fix linkifying ssb URIs
-rw-r--r--lib/render.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/render.js b/lib/render.js
index 66f4e7f..91bd2ab 100644
--- a/lib/render.js
+++ b/lib/render.js
@@ -251,7 +251,7 @@ Render.prototype.toUrl = function (href) {
if (!href) return href
var mentions = this._mentions
if (mentions && href in this._mentions) href = this._mentions[href]
- if (/^ssb:\/\//.test(href)) href = href.substr(6)
+ if (/^ssb:/.test(href)) href = u.translateFromURI(href) || href
if (/^ssb-blob:\/\//.test(href)) {
return this.opts.base + 'zip/' + href.substr(11)
}