From 8cd531187bc6d98f6fffd9d7eb927390e4941002 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E8=BF=9C=E6=B5=85?=
<14177215+unliar@users.noreply.github.com>
Date: Thu, 26 Dec 2024 23:48:54 +0800
Subject: [PATCH] fix: weibo livephoto get wrong object key (#17985)
---
lib/routes/weibo/utils.ts | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/lib/routes/weibo/utils.ts b/lib/routes/weibo/utils.ts
index 8dec9603da0c1e..729150d827454c 100644
--- a/lib/routes/weibo/utils.ts
+++ b/lib/routes/weibo/utils.ts
@@ -132,8 +132,8 @@ const weiboUtils = {
}
// drop live photo
- const livePhotoCount = status.pics ? status.pics.filter((pic) => pic.type === 'livephotos').length : 0;
- const pics = status.pics && status.pics.filter((pic) => pic.type !== 'livephotos');
+ const livePhotoCount = status.pics ? status.pics.filter((pic) => pic.type === 'livephoto').length : 0;
+ const pics = status.pics && status.pics.filter((pic) => pic.type !== 'livephoto');
// 添加微博配图
if (pics) {
@@ -263,7 +263,7 @@ const weiboUtils = {
},
formatVideo: (itemDesc, status) => {
const pageInfo = status.page_info;
- const livePhotos = status.pics && status.pics.filter((pic) => pic.type === 'livephotos' && pic.videoSrc);
+ const livePhotos = status.pics && status.pics.filter((pic) => pic.type === 'livephoto' && pic.videoSrc);
let video = '