From 6bfe030eadd7d9d8a48fa45dc2450cf1de8024b6 Mon Sep 17 00:00:00 2001 From: tangly1024 Date: Thu, 31 Mar 2022 10:07:25 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=A0=E9=94=81=E6=96=87=E7=AB=A0RSS?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/rss.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/rss.js b/lib/rss.js index cd541463..045ca082 100644 --- a/lib/rss.js +++ b/lib/rss.js @@ -7,6 +7,10 @@ import { getPostBlocks } from './notion' const mapPageUrl = id => 'https://www.notion.so/' + id.replace(/-/g, '') const createFeedContent = async post => { + // 加密的文章内容只返回摘要 + if (post.password && post.password !== '') { + return post.summary + } const blockMap = await getPostBlocks(post.id, 'rss-content') if (blockMap) { const content = ReactDOMServer.renderToString(