mirror of
https://github.com/misskey-dev/summaly.git
synced 2025-05-11 00:27:35 +09:00
Fix bug
This commit is contained in:
parent
c981350893
commit
a89d737945
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "summaly",
|
"name": "summaly",
|
||||||
"version": "1.1.2",
|
"version": "1.1.3",
|
||||||
"description": "Get web page's summary",
|
"description": "Get web page's summary",
|
||||||
"author": "syuilo <i@syuilo.com>",
|
"author": "syuilo <i@syuilo.com>",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
|
@ -17,7 +17,7 @@ exports.summary = async (url: URL.Url) => {
|
|||||||
const isDesktop = !/\.m\.wikipedia\.org$/.test(url.hostname);
|
const isDesktop = !/\.m\.wikipedia\.org$/.test(url.hostname);
|
||||||
const text: string = isDesktop
|
const text: string = isDesktop
|
||||||
? $('#mw-content-text > p:first-of-type').text()
|
? $('#mw-content-text > p:first-of-type').text()
|
||||||
: $('#bodyContent > div:first-of-type > p:first-of-type').text();
|
: $('#mw-content-text > div:first-of-type > p:first-of-type').text();
|
||||||
|
|
||||||
return {
|
return {
|
||||||
title: decodeURI(url.pathname.split('/')[2]),
|
title: decodeURI(url.pathname.split('/')[2]),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user