From 2ecf74cdf2e7b1b69205366a60ea04922a81ecf6 Mon Sep 17 00:00:00 2001 From: Anton SHEPILOV Date: Sat, 9 Mar 2024 09:48:58 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9BTemporary=20fix=20for=20twake=20cli?= =?UTF-8?q?ent=20auth=20in=20plugin?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../utils/nextcloud-migration/src/twake_client.ts | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/tdrive/backend/utils/nextcloud-migration/src/twake_client.ts b/tdrive/backend/utils/nextcloud-migration/src/twake_client.ts index 41ce0652..dc73b1fc 100644 --- a/tdrive/backend/utils/nextcloud-migration/src/twake_client.ts +++ b/tdrive/backend/utils/nextcloud-migration/src/twake_client.ts @@ -127,14 +127,12 @@ export class TwakeDriveClient { } private async client() { - if (!this.clientInstance) { - this.clientInstance = axios.create({ - baseURL: this.config.url, - headers: { - Authorization: `Bearer ${await (this.accessToken())}`, - }, - }); - } + this.clientInstance = axios.create({ + baseURL: this.config.url, + headers: { + Authorization: `Bearer ${await (this.accessToken())}`, + }, + }); return this.clientInstance; }