Skip to content

Commit

Permalink
fix: e.isLid is not a function
Browse files Browse the repository at this point in the history
  • Loading branch information
jrrcdev committed Jul 9, 2022
1 parent 15b6984 commit 88209cf
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/wapi/functions/check-number-status.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export async function checkNumberStatus(id, conn = false) {

if (WAPI.isBeta()) {
return await Store.checkNumberBeta
.queryExists(id)
.queryExists(new Store.WidFactory.createWid(id))
.then((result) => {
if (!!result && typeof result === 'object') {
const data = {
Expand Down
9 changes: 9 additions & 0 deletions src/lib/wapi/functions/check-send-exist.js
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,15 @@ export function sendCheckType(chatId = undefined) {
'incorrect parameters! Use as an example: 00000000-000000@g.us or 00000000000000@g.us'
);
}

if (!Store.WidFactory.isWidlike(chatId)) {
return WAPI.scope(
chatId,
true,
404,
'The number does not exist. Invalid wid!'
);
}
}
}

Expand Down

0 comments on commit 88209cf

Please sign in to comment.