diff --git a/plugin/src/services/sync-service.ts b/plugin/src/services/sync-service.ts index d5f4cbc..d2c460c 100644 --- a/plugin/src/services/sync-service.ts +++ b/plugin/src/services/sync-service.ts @@ -19,6 +19,7 @@ export interface CheckConnectionResult { } export class SyncService { private client: Client; + private clientWithoutRetries: Client; public constructor(private readonly database: Database) { this.createClient(database.getSettings()); @@ -41,7 +42,7 @@ export class SyncService { } public async ping(): Promise { - const response = await this.client.GET("/ping", { + const response = await this.clientWithoutRetries.GET("/ping", { params: { header: { authorization: `Bearer ${ @@ -304,5 +305,9 @@ export class SyncService { baseUrl: settings.remoteUri, fetch: retriedFetch, }); + + this.clientWithoutRetries = createClient({ + baseUrl: settings.remoteUri, + }); } }