whatsapp-web.js 1.17.0 → 1.17.1
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/README.md +1 -0
- package/index.d.ts +3 -1
- package/package.json +1 -1
- package/src/Client.js +3 -2
package/README.md
CHANGED
|
@@ -80,6 +80,7 @@ For more information on saving and restoring sessions, check out the available [
|
|
|
80
80
|
| Get contact info | ✅ |
|
|
81
81
|
| Get profile pictures | ✅ |
|
|
82
82
|
| Set user status message | ✅ |
|
|
83
|
+
| React to messages | ✅ |
|
|
83
84
|
|
|
84
85
|
Something missing? Make an issue and let us know!
|
|
85
86
|
|
package/index.d.ts
CHANGED
|
@@ -604,6 +604,8 @@ declare namespace WAWebJS {
|
|
|
604
604
|
ack: MessageAck,
|
|
605
605
|
/** If the message was sent to a group, this field will contain the user that sent the message. */
|
|
606
606
|
author?: string,
|
|
607
|
+
/** String that represents from which device type the message was sent */
|
|
608
|
+
deviceType: string,
|
|
607
609
|
/** Message content */
|
|
608
610
|
body: string,
|
|
609
611
|
/** Indicates if the message was a broadcast */
|
|
@@ -704,7 +706,7 @@ declare namespace WAWebJS {
|
|
|
704
706
|
*/
|
|
705
707
|
reply: (content: MessageContent, chatId?: string, options?: MessageSendOptions) => Promise<Message>,
|
|
706
708
|
/** React to this message with an emoji*/
|
|
707
|
-
react: (reaction: string) => Promise
|
|
709
|
+
react: (reaction: string) => Promise<void>,
|
|
708
710
|
/**
|
|
709
711
|
* Forwards this message to another chat
|
|
710
712
|
*/
|
package/package.json
CHANGED
package/src/Client.js
CHANGED
|
@@ -132,7 +132,7 @@ class Client extends EventEmitter {
|
|
|
132
132
|
})
|
|
133
133
|
]);
|
|
134
134
|
|
|
135
|
-
// Checks if an error
|
|
135
|
+
// Checks if an error occurred on the first found selector. The second will be discarded and ignored by .race;
|
|
136
136
|
if (needAuthentication instanceof Error) throw needAuthentication;
|
|
137
137
|
|
|
138
138
|
// Scan-qrcode selector was found. Needs authentication
|
|
@@ -949,7 +949,8 @@ class Client extends EventEmitter {
|
|
|
949
949
|
}
|
|
950
950
|
|
|
951
951
|
return await this.pupPage.evaluate(async number => {
|
|
952
|
-
const
|
|
952
|
+
const wid = window.Store.WidFactory.createWid(number);
|
|
953
|
+
const result = await window.Store.QueryExist(wid);
|
|
953
954
|
if (!result || result.wid === undefined) return null;
|
|
954
955
|
return result.wid;
|
|
955
956
|
}, number);
|