Fix crash on wierd non-string names
This commit is contained in:
+1
-1
@@ -26,7 +26,7 @@ module.exports = function (sbot, id, cb) {
|
|||||||
var c = msg.value.content
|
var c = msg.value.content
|
||||||
if (!c) return
|
if (!c) return
|
||||||
var feedAbout = aboutByFeed[author] || (aboutByFeed[author] = {})
|
var feedAbout = aboutByFeed[author] || (aboutByFeed[author] = {})
|
||||||
if (c.name) feedAbout.name = c.name.replace(/^@?/, '@')
|
if (typeof c.name == 'string') feedAbout.name = c.name.replace(/^@?/, '@')
|
||||||
if (c.image) feedAbout.image = linkDest(c.image)
|
if (c.image) feedAbout.image = linkDest(c.image)
|
||||||
if (c.description) feedAbout.description = c.description
|
if (c.description) feedAbout.description = c.description
|
||||||
if (c.publicWebHosting != null && author === c.about) feedAbout.publicWebHosting = defalsify(c.publicWebHosting)
|
if (c.publicWebHosting != null && author === c.about) feedAbout.publicWebHosting = defalsify(c.publicWebHosting)
|
||||||
|
|||||||
Reference in New Issue
Block a user