mirror of
https://github.com/misskey-dev/summaly.git
synced 2025-05-09 07:37:18 +09:00
Fix bug (1.4.1)
This commit is contained in:
parent
3d0a5995ff
commit
12463da014
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "summaly",
|
||||
"version": "1.4.0",
|
||||
"version": "1.4.1",
|
||||
"description": "Get web page's summary",
|
||||
"author": "syuilo <i@syuilo.com>",
|
||||
"license": "MIT",
|
||||
|
@ -10,7 +10,7 @@ exports.test = (url: URL.Url) =>
|
||||
exports.summary = (url: URL.Url) => new Promise((res, rej) => {
|
||||
const lang = url.host.split('.')[0];
|
||||
const title = url.pathname.split('/')[2];
|
||||
const endpoint = `https://${lang}.wikipedia.org/w/api.php?format=json&action=query&prop=extracts&exintro=&explaintext=&titles=${title}`;
|
||||
const endpoint = `https://${lang}.wikipedia.org/w/api.php?format=json&action=query&prop=extracts&exintro=&explaintext=&titles=${encodeURIComponent(title)}`;
|
||||
|
||||
log(`lang is ${lang}`);
|
||||
log(`title is ${title}`);
|
||||
|
@ -17,7 +17,7 @@
|
||||
"jsdoc-format": true,
|
||||
"label-position": true,
|
||||
"label-undefined": true,
|
||||
"max-line-length": [true, 140],
|
||||
"max-line-length": false,
|
||||
"member-access": false,
|
||||
"member-ordering": [true,
|
||||
"static-before-instance",
|
||||
|
Loading…
x
Reference in New Issue
Block a user