Spaces:
Paused
Paused
Download utils/helpers.js from Mega-Evolutions/empty: direct link, hf CLI and curl.
- Browser
- Download file 288 Bytes
-
https://huggingface.co/spaces/Mega-Evolutions/empty/resolve/main/utils/helpers.js
- Command line
-
hf download hf://spaces/Mega-Evolutions/empty/utils/helpers.js
-
curl -L -o helpers.js https://huggingface.co/spaces/Mega-Evolutions/empty/resolve/main/utils/helpers.js
288 Bytes
| export function normalizeJid(jid) { | |
| return jid.replace(/@lid$/, '@s.whatsapp.net') | |
| } | |
| export function getUserNumber(jid) { | |
| const cleanJid = normalizeJid(jid) | |
| return cleanJid.split('@')[0] | |
| } | |
| export function isGroupJid(jid) { | |
| return jid.endsWith('@g.us') || jid.endsWith('@lid') | |
| } | |