Skip to content

Commit 97b3f9b

Browse files
committed
fix: Fix the problem when disconnecting the instance and connecting again using mongodb
1 parent e8764dd commit 97b3f9b

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/whatsapp/services/whatsapp.service.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1234,15 +1234,17 @@ export class WAStartupService {
12341234
this.instance.wuid = this.client.user.id.replace(/:\d+/, '');
12351235
this.instance.profilePictureUrl = (await this.profilePicture(this.instance.wuid)).profilePictureUrl;
12361236
const formattedWuid = this.instance.wuid.split('@')[0].padEnd(30, ' ');
1237-
const formattedName = this.instance.name.split('@')[0].padEnd(30, ' ');
1237+
const formattedName = this.instance.name;
12381238
this.logger.info(
12391239
`
12401240
┌──────────────────────────────┐
12411241
│ CONNECTED TO WHATSAPP │
1242-
${formattedWuid}
1243-
${formattedName}
12441242
└──────────────────────────────┘`.replace(/^ +/gm, ' '),
12451243
);
1244+
this.logger.info(`
1245+
wuid: ${formattedWuid}
1246+
name: ${formattedName}
1247+
`);
12461248

12471249
if (this.localChatwoot.enabled) {
12481250
this.chatwootService.eventWhatsapp(

0 commit comments

Comments
 (0)