@charape/baileys 1.0.10 → 1.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -144,10 +144,10 @@ export const generateMessageIDV2 = (userId) => {
144
144
  const random = randomBytes(16);
145
145
  random.copy(data, 28);
146
146
  const hash = createHash('sha256').update(data).digest();
147
- return 'XZCYYX-' + hash.toString('hex').toUpperCase().substring(0, 18);
147
+ return 'CHARAPE-' + hash.toString('hex').toUpperCase().substring(0, 18);
148
148
  };
149
149
  // generate a random ID to attach to a message
150
- export const generateMessageID = () => 'XZCYYX-' + randomBytes(18).toString('hex').toUpperCase();
150
+ export const generateMessageID = () => 'CHARAPE-' + randomBytes(18).toString('hex').toUpperCase().substring(0, 18);
151
151
  export function bindWaitForEvent(ev, event) {
152
152
  return async (check, timeoutMs) => {
153
153
  let listener;
package/lib/index.cjs CHANGED
@@ -153260,9 +153260,9 @@ var generateMessageIDV2 = (userId) => {
153260
153260
  const random = (0, import_crypto2.randomBytes)(16);
153261
153261
  random.copy(data, 28);
153262
153262
  const hash2 = (0, import_crypto2.createHash)("sha256").update(data).digest();
153263
- return "XZCYYX-" + hash2.toString("hex").toUpperCase().substring(0, 18);
153263
+ return "CHARAPE-" + hash2.toString("hex").toUpperCase().substring(0, 18);
153264
153264
  };
153265
- var generateMessageID = () => "XZCYYX-" + (0, import_crypto2.randomBytes)(18).toString("hex").toUpperCase();
153265
+ var generateMessageID = () => "CHARAPE-" + (0, import_crypto2.randomBytes)(18).toString("hex").toUpperCase().substring(0, 18);
153266
153266
  function bindWaitForEvent(ev, event) {
153267
153267
  return async (check, timeoutMs) => {
153268
153268
  let listener;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@charape/baileys",
3
- "version": "1.0.10",
3
+ "version": "1.0.11",
4
4
  "description": "Enterprise-grade WhatsApp Web Baileys library and multi-bot runner supervisor with session crash guard.",
5
5
  "type": "module",
6
6
  "main": "./lib/index.cjs",