refactor(eslint): change unused vars rule to error and update error handling in services

- Update ESLint configuration to set `@typescript-eslint/no-unused-vars` from 'warn' to 'error' for stricter linting.
- Refactor error handling in various services to omit error variable in catch blocks for cleaner code.
This commit is contained in:
Davidson Gomes
2025-09-18 14:59:33 -03:00
parent 0787a10f39
commit 5e08628d89
8 changed files with 29 additions and 29 deletions

View File

@@ -130,7 +130,7 @@ export class ChatwootService {
public async find(instance: InstanceDto): Promise<ChatwootDto> {
try {
return await this.waMonitor.waInstances[instance.instanceName].findChatwoot();
} catch (error) {
} catch {
this.logger.error('chatwoot not found');
return { enabled: null, url: '' };
}
@@ -370,7 +370,7 @@ export class ChatwootService {
});
return contact;
} catch (error) {
} catch {
return null;
}
}
@@ -407,7 +407,7 @@ export class ChatwootService {
}
return true;
} catch (error) {
} catch {
return false;
}
}
@@ -2552,7 +2552,7 @@ export class ChatwootService {
await chatwootImport.importHistoryMessages(instance, this, inbox, this.provider);
const waInstance = this.waMonitor.waInstances[instance.instanceName];
waInstance.clearCacheChatwoot();
} catch (error) {
} catch {
return;
}
}