From 970f333bb490722d120c6b511a2591ad503b7623 Mon Sep 17 00:00:00 2001 From: Adhiraj Date: Tue, 14 Jul 2020 21:40:49 +0530 Subject: [PATCH] group create response fix --- src/WAClient/Tests.ts | 2 +- src/WAConnection/Constants.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/WAClient/Tests.ts b/src/WAClient/Tests.ts index e1ff933..a50dbfe 100644 --- a/src/WAClient/Tests.ts +++ b/src/WAClient/Tests.ts @@ -155,7 +155,7 @@ WAClientTest('Groups', (client) => { it('should create a group', async () => { const response = await client.groupCreate('Cool Test Group', [testJid]) gid = response.gid - console.log('created group: ' + gid) + console.log('created group: ' + JSON.stringify(response)) }) it('should retreive group invite code', async () => { const code = await client.groupInviteCode(gid) diff --git a/src/WAConnection/Constants.ts b/src/WAConnection/Constants.ts index 5543f30..310ceff 100644 --- a/src/WAConnection/Constants.ts +++ b/src/WAConnection/Constants.ts @@ -38,7 +38,7 @@ export type WAMessageContent = proto.IMessage export interface WAGroupCreateResponse { status: number gid?: string - participants?: { [key: string]: any } + participants?: [{ [key: string]: any }] } export interface WAGroupMetadata { id: string