mezon-js-protobuf 1.8.77 → 1.8.78

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.
package/utils.ts CHANGED
@@ -5,7 +5,7 @@ export function decodeMentions(data: any) {
5
5
  const uintBuffer: Uint8Array = new Uint8Array(buffer);
6
6
  const mentions = tsproto.MessageMentionList.decode(uintBuffer);
7
7
 
8
- return mentions
8
+ return mentions;
9
9
  }
10
10
 
11
11
  export function decodeAttachments(data: any) {
@@ -13,7 +13,7 @@ export function decodeAttachments(data: any) {
13
13
  const uintBuffer: Uint8Array = new Uint8Array(buffer);
14
14
  const attachments = tsproto.MessageAttachmentList.decode(uintBuffer);
15
15
 
16
- return attachments
16
+ return attachments;
17
17
  }
18
18
 
19
19
  export function decodeRefs(data: any) {
@@ -21,7 +21,14 @@ export function decodeRefs(data: any) {
21
21
  const uintBuffer: Uint8Array = new Uint8Array(buffer);
22
22
  const refs = tsproto.MessageRefList.decode(uintBuffer);
23
23
 
24
- return refs
24
+ return refs;
25
+ }
26
+
27
+ export function decodeReactions(data: any) {
28
+ const buffer: ArrayBuffer = data;
29
+ const uintBuffer: Uint8Array = new Uint8Array(buffer);
30
+ const noti = tsproto.MessageReactionList.decode(uintBuffer);
31
+ return noti;
25
32
  }
26
33
 
27
34
  export function decodeNotificationFcm(data: any) {
@@ -29,5 +36,5 @@ export function decodeNotificationFcm(data: any) {
29
36
  const uintBuffer: Uint8Array = new Uint8Array(buffer);
30
37
  const noti = tsproto.DirectFcmProto.decode(uintBuffer);
31
38
 
32
- return noti
39
+ return noti;
33
40
  }