fix: logout wa business instance

This commit is contained in:
Davidson Gomes
2024-02-18 07:52:21 -03:00
parent bc6944736e
commit a931ee7afb
3 changed files with 14 additions and 5 deletions

View File

@@ -147,6 +147,14 @@ export class BaileysStartupService extends WAStartupService {
return this.stateConnection;
}
public async logoutInstance() {
this.logger.verbose('logging out instance: ' + this.instanceName);
await this.client?.logout('Log out instance: ' + this.instanceName);
this.logger.verbose('close connection instance: ' + this.instanceName);
this.client?.ws?.close();
}
public async getProfileName() {
this.logger.verbose('Getting profile name');