From f32ca2bdcfcb8a4943f6c932a955d1365f14abf1 Mon Sep 17 00:00:00 2001 From: capitanwesler Date: Tue, 1 Jun 2021 21:24:52 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=98=8E=20Encoding=20URI=20parameters=20in?= =?UTF-8?q?=20qwant=20call?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- package.json | 2 +- src/controllers/UtilsController.ts | 4 +++- src/routes.ts | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 3b85070..0e2a45c 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# **Aruppi API** (v4.1.1) +# **Aruppi API** (v4.1.2) > This API has everything about Japan, from anime, music, radio, images, videos ... to japanese culture > diff --git a/package.json b/package.json index 77796bd..ff1770d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "aruppi", - "version": "4.1.1", + "version": "4.1.2", "description": "Aruppi is a custom API to obtain data from the Japanese culture for the mobile app", "main": "./src/api/api.ts", "scripts": { diff --git a/src/controllers/UtilsController.ts b/src/controllers/UtilsController.ts index 3faf599..ae8a0d9 100644 --- a/src/controllers/UtilsController.ts +++ b/src/controllers/UtilsController.ts @@ -231,7 +231,9 @@ export default class UtilsController { } data = await requestGot( - `${urls.BASE_QWANT}count=51&q=${title}&t=images&safesearch=1&locale=es_ES&uiv=4`, + encodeURI( + `{urls.BASE_QWANT}t=images&q=${title}&count=51&locale=es_ES&safesearch=1`, + ), { scrapy: false, parse: true }, ); } catch (err) { diff --git a/src/routes.ts b/src/routes.ts index 566b733..8744681 100644 --- a/src/routes.ts +++ b/src/routes.ts @@ -26,7 +26,7 @@ routes.get('/api/v4/', (req: Request, res: Response) => { res.json({ message: 'Aruppi /api - 🎏', author: 'Jéluchu', - version: '4.1.1', + version: '4.1.2', credits: 'The bitch loves /apis that offers data to Aruppi App', entries: [ {