From 697feb1b172d0220432dbd383151367fc3c9ed33 Mon Sep 17 00:00:00 2001 From: gekkedev <17025257+gekkedev@users.noreply.github.com> Date: Thu, 24 Oct 2024 18:33:39 +0200 Subject: [PATCH] fix: Fixed getChatById typos (#2353) --- src/api/layers/retriever.layer.ts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/api/layers/retriever.layer.ts b/src/api/layers/retriever.layer.ts index 62820857a..ad7e48964 100644 --- a/src/api/layers/retriever.layer.ts +++ b/src/api/layers/retriever.layer.ts @@ -180,7 +180,7 @@ export class RetrieverLayer extends SenderLayer { * Checks if a number is a valid WA number * @category Contact * @param contactId, you need to include the @c.us at the end. - * @returns contact detial as promise + * @returns contact details as promise */ public async checkNumberStatus(contactId: string): Promise { return await evaluateAndReturn( @@ -256,7 +256,7 @@ export class RetrieverLayer extends SenderLayer { * Retrieves contact detail object of given contact id * @category Contact * @param contactId - * @returns contact detial as promise + * @returns contact details as promise */ public async getContact(contactId: string) { return evaluateAndReturn( @@ -279,9 +279,9 @@ export class RetrieverLayer extends SenderLayer { * Retrieves chat object of given contact id * @category Chat * @param contactId - * @returns contact detial as promise + * @returns chat details as promise */ - public async getChatById(contactId: string): Promise { + public async getChatById(contactId: string | Wid): Promise { return evaluateAndReturn( this.page, (contactId) => WAPI.getChatById(contactId), @@ -293,10 +293,10 @@ export class RetrieverLayer extends SenderLayer { * Retrieves chat object of given contact id * @category Chat * @param contactId - * @returns contact detial as promise + * @returns chat details as promise * @deprecated */ - public async getChat(contactId: string) { + public async getChat(contactId: string | Wid) { return this.getChatById(contactId); } @@ -323,7 +323,7 @@ export class RetrieverLayer extends SenderLayer { * @deprecated Depreciado em favor de getMessages * @category Chat * @param contactId - * @returns contact detial as promise + * @returns contact details as promise */ public async loadEarlierMessages(contactId: string) { return evaluateAndReturn( @@ -360,7 +360,7 @@ export class RetrieverLayer extends SenderLayer { * @deprecated Deprecated in favor of checkNumberStatus * @category Contact * @param contactId, you need to include the @c.us at the end. - * @returns contact detial as promise + * @returns contact details as promise */ public async getNumberProfile(contactId: string) { this.log(