@baileys-md/baileys 11.0.2 → 11.0.3

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.
@@ -3,8 +3,8 @@ import * as Defaults_1 from "../Defaults/index.js"
3
3
  import * as LabelAssociation_1 from "../Types/LabelAssociation.js"
4
4
  import * as Utils_1 from "../Utils/index.js"
5
5
  import * as WABinary_1 from "../WABinary/index.js"
6
- import make_ordered_dictionary_1 from "./make-ordered-dictionary.js"
7
6
  import * as object_repository_1 from "./object-repository.js"
7
+ import * as make_ordered_dictionary_1 from "./make-ordered-dictionary.js"
8
8
  export const waChatKey = (pin) => ({
9
9
  key: (c) => (pin ? (c.pinned ? '1' : '0') : '') + (c.archived ? '0' : '1') + (c.conversationTimestamp ? c.conversationTimestamp.toString(16).padStart(8, '0') : '') + c.id,
10
10
  compare: (k1, k2) => k2.localeCompare(k1)
@@ -14,7 +14,7 @@ export const waLabelAssociationKey = {
14
14
  key: (la) => (la.type === LabelAssociation_1.LabelAssociationType.Chat ? la.chatId + la.labelId : la.chatId + la.messageId + la.labelId),
15
15
  compare: (k1, k2) => k2.localeCompare(k1)
16
16
  };
17
- const makeMessagesDictionary = () => (0, make_ordered_dictionary_1)(waMessageID);
17
+ const makeMessagesDictionary = () => (0, make_ordered_dictionary_1.makeOrderedDictionary)(waMessageID);
18
18
  export const makeInMemoryStore = async (config) => {
19
19
  const socket = config.socket;
20
20
  const chatKey = config.chatKey || (0, waChatKey)(true);
@@ -1,4 +1,4 @@
1
- function makeOrderedDictionary(idGetter) {
1
+ export const makeOrderedDictionary = (idGetter) => {
2
2
  const array = [];
3
3
  const dict = {};
4
4
  const get = (id) => dict[id];
@@ -75,5 +75,4 @@ function makeOrderedDictionary(idGetter) {
75
75
  array.splice(0, array.length, ...newItems);
76
76
  }
77
77
  };
78
- }
79
- export default makeOrderedDictionary;
78
+ }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@baileys-md/baileys",
3
3
  "type": "module",
4
- "version": "11.0.2",
4
+ "version": "11.0.3",
5
5
  "description": "A WebSockets library for interacting with WhatsApp Web",
6
6
  "keywords": [
7
7
  "whatsapp",