Skip to content

Commit

Permalink
fix: Fixed getChatById typos (#2353)
Browse files Browse the repository at this point in the history
  • Loading branch information
gekkedev authored Oct 24, 2024
1 parent 1a40579 commit 697feb1
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/api/layers/retriever.layer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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<WhatsappProfile> {
return await evaluateAndReturn(
Expand Down Expand Up @@ -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(
Expand All @@ -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<Chat> {
public async getChatById(contactId: string | Wid): Promise<Chat> {
return evaluateAndReturn(
this.page,
(contactId) => WAPI.getChatById(contactId),
Expand All @@ -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);
}

Expand All @@ -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(
Expand Down Expand Up @@ -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(
Expand Down

0 comments on commit 697feb1

Please sign in to comment.