diff --git a/lib/v2/lofter/user.js b/lib/v2/lofter/user.js index f3a7466f2..c99d2f4b4 100644 --- a/lib/v2/lofter/user.js +++ b/lib/v2/lofter/user.js @@ -37,10 +37,10 @@ module.exports = async (ctx) => { description: JSON.parse(item.post.photoLinks || `[]`) .map((photo) => { - if (photo.raw.match(/\/\/nos\.netease\.com\//)) { + if (photo.raw?.match(/\/\/nos\.netease\.com\//)) { photo.raw = `https://${photo.raw.match(/(imglf\d)/)[0]}.lf127.net${photo.raw.match(/\/\/nos\.netease\.com\/imglf\d(.*)/)[1]}`; } - return ``; + return ``; }) .join('') + JSON.parse(item.post.embed ? `[${item.post.embed}]` : `[]`)