diff --git a/lib/routes/weibo/user.js b/lib/routes/weibo/user.js index 742e55d25..ed3e2a19c 100644 --- a/lib/routes/weibo/user.js +++ b/lib/routes/weibo/user.js @@ -61,7 +61,7 @@ module.exports = async (ctx) => { const link = `https://weibo.com/${uid}/${item.mblog.bid}`; let description = weiboUtils.format(item.mblog); - const title = description.replace(//g, '[图片]').replace(/<.*?>/g, ''); + const title = description.replace(//g, '[图片]').replace(/<.*?>/g, ''); const pubDate = isDataOK ? new Date(data.created_at).toUTCString() : date(item.mblog.created_at, 8); // 视频的处理 diff --git a/lib/routes/weibo/utils.js b/lib/routes/weibo/utils.js index 7b3912d30..02fac9c5a 100644 --- a/lib/routes/weibo/utils.js +++ b/lib/routes/weibo/utils.js @@ -5,7 +5,7 @@ const weiboUtils = { // 长文章的处理 let temp = (status.longText && status.longText.longTextContent.replace(/\n/g, '
')) || status.text || ''; // 表情图标转换为文字 - temp = temp.replace(/<\/span>/g, '$1'); + temp = temp.replace(/<\/span>/g, '$1'); // 去掉外部链接的图标 temp = temp.replace(/.*?<\/span>(.*?)<\/span>/g, '$1'); // 去掉乱七八糟的图标