From 85164d79fc54cae57731a38458d9cec81a8136af Mon Sep 17 00:00:00 2001 From: ajnart Date: Tue, 21 Jun 2022 20:35:40 +0200 Subject: [PATCH] :ambulance: Hotfix password and usernames --- src/pages/api/modules/downloads.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/pages/api/modules/downloads.ts b/src/pages/api/modules/downloads.ts index ccb483254..0cc5236df 100644 --- a/src/pages/api/modules/downloads.ts +++ b/src/pages/api/modules/downloads.ts @@ -35,7 +35,7 @@ async function Post(req: NextApiRequest, res: NextApiResponse) { delugeServices.map((service) => new Deluge({ baseUrl: service.url, - password: service.password, + password: 'password' in service ? service.password : '', }) .getAllData() .then((e) => e.torrents.map((torrent) => torrents.push(torrent))) @@ -46,8 +46,8 @@ async function Post(req: NextApiRequest, res: NextApiResponse) { transmissionServices.map((service) => new Transmission({ baseUrl: service.url, - username: service.username, - password: service.password, + username: 'username' in service ? service.username : '', + password: 'password' in service ? service.password : '', }) .getAllData() .then((e) => e.torrents.map((torrent) => torrents.push(torrent)))