Skip to content

Commit

Permalink
fix: 重新支持infoq获取文章正文 (DIYgod#12039)
Browse files Browse the repository at this point in the history
* 重新支持获取文章正文

* Update lib/v2/infoq/utils.js

* Update lib/v2/infoq/utils.js

* style: auto format

---------
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
lin1005q authored Mar 6, 2023
1 parent 9498669 commit 1878fca
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/v2/infoq/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,11 @@ const ProcessFeed = async (list, cache) => {
const data = resp.data.data;
const author = data.author ? data.author.map((p) => p.nickname).join(',') : data.no_author;
const category = e.topic.map((t) => t.name).concat(e.label.map((l) => l.name));
const content = data.content_url ? (await got(data.content_url)).body : data.content;

return {
title: data.article_title,
description: parseContent(data.content),
description: parseContent(content),
pubDate: parseDate(e.publish_time, 'x'),
category,
author,
Expand Down

0 comments on commit 1878fca

Please sign in to comment.