From 6fe21dbcb72e9399ff0c35f26ba1956b7484dfe2 Mon Sep 17 00:00:00 2001 From: zytomorrow Date: Tue, 3 Mar 2020 00:48:34 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E8=A7=A3=E5=86=B3=E5=BE=AE=E5=8D=9A?= =?UTF-8?q?=E6=97=B6=E9=97=B4=E7=BA=BFlink=E7=9B=B8=E5=90=8C=E6=97=B6?= =?UTF-8?q?=E8=A2=AB=E5=A4=84=E7=90=86=E6=88=90=E5=90=8C=E6=A0=B7=E7=9A=84?= =?UTF-8?q?=E5=BE=AE=E5=8D=9A=20(#4152)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/routes/weibo/timeline.js | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/lib/routes/weibo/timeline.js b/lib/routes/weibo/timeline.js index a6a10946a..ed91e75c4 100644 --- a/lib/routes/weibo/timeline.js +++ b/lib/routes/weibo/timeline.js @@ -96,27 +96,12 @@ module.exports = async (ctx) => { } else { title = `${item.user.name}--原创微博`; } - let link = 'https://weibo.com'; - try { - await got.get(`http://api.weibo.com/2/statuses/go?access_token=${token}&id=${item.id}&uid=${item.user.id}`, { - hooks: { - beforeRedirect: [ - (options) => { - options.followRedirect = false; - link = options.href; - }, - ], - }, - }); - } catch (error) { - // nothing - } return { title: title, content: content, author: item.user.name, date: item.created_at, - link: link, + link: `https://m.weibo.cn/detail/${item.id}`, pic_urls: picUrlList, videoList, };