diff options
author | cel <cel@f/6sQ6d2CMxRUhLpspgGIulDxDCwYD7DzFzPNr7u5AU=.ed25519> | 2019-12-14 09:16:31 -1000 |
---|---|---|
committer | cel <cel@f/6sQ6d2CMxRUhLpspgGIulDxDCwYD7DzFzPNr7u5AU=.ed25519> | 2019-12-14 09:16:31 -1000 |
commit | de6d39cedeb4af0e54ca04583ad3fe33e2ef094a (patch) | |
tree | d28125d512c6fc331fa1fedc9efad0c5aecc9710 /lib/render.js | |
parent | 0bd830cf4ebf9cf3e4df1f2dba4b851b9361fc14 (diff) | |
download | patchfoo-de6d39cedeb4af0e54ca04583ad3fe33e2ef094a.tar.gz patchfoo-de6d39cedeb4af0e54ca04583ad3fe33e2ef094a.zip |
Sanitize strings
Calling String on an object with a toString property would throw an error
Diffstat (limited to 'lib/render.js')
-rw-r--r-- | lib/render.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/render.js b/lib/render.js index 1aec728..e694396 100644 --- a/lib/render.js +++ b/lib/render.js @@ -190,7 +190,7 @@ Render.prototype.markdown = function (text, mentions, opts) { var out = ssbcMd ? md.block(String(text), { toUrl: function (ref) { return self.toUrl(ref) }, imageLink: function (ref) { return self.imageUrl(ref) } - }) : marked(String(text), this.markedOpts) + }) : marked(u.toString(text), this.markedOpts) delete this._mentions delete this._mentionsByLink return out //fixSymbols(out) |