node-easywechat 2.7.1 → 2.7.2
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/dist/Core/Messages/Message.js +1 -3
- package/dist/Core/ServerGuard.d.ts +1 -0
- package/dist/Core/ServerGuard.js +3 -0
- package/node-easywechat.file_cache.easywechat.kernel.access_token.8a9684b45da7de42a06a70ba01a7005a.cache +1 -1
- package/node-easywechat.file_cache.easywechat.kernel.access_token.c3d06edaf326aad75d32f31348df787a.cache +1 -1
- package/package.json +1 -1
|
@@ -17,9 +17,7 @@ class Message {
|
|
|
17
17
|
this.type = type;
|
|
18
18
|
}
|
|
19
19
|
transformToXml(appends = {}, returnAsObject = false) {
|
|
20
|
-
let data = {
|
|
21
|
-
xml: Utils_1.merge(Utils_1.merge({ MsgType: this.getType() }, this.toXmlArray()), appends)
|
|
22
|
-
};
|
|
20
|
+
let data = Utils_1.merge(Utils_1.merge({ MsgType: this.getType() }, this.toXmlArray()), appends);
|
|
23
21
|
if (returnAsObject) {
|
|
24
22
|
return data;
|
|
25
23
|
}
|
|
@@ -27,6 +27,7 @@ export default class ServerGuard {
|
|
|
27
27
|
* @param condition EasyWechat.Messages.Message.xxx,用于处理特定消息类型,默认:* 表示全部
|
|
28
28
|
*/
|
|
29
29
|
push(handler: ServerHandler, condition?: string): void;
|
|
30
|
+
setHandlers(handlers?: ServerHandlers): void;
|
|
30
31
|
protected dispatch(event: string, payload: any): Promise<any>;
|
|
31
32
|
protected notify(event: string, payload: any): Promise<any>;
|
|
32
33
|
protected _callHandler(handler: ServerHandler, payload: any): Promise<any>;
|
package/dist/Core/ServerGuard.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"data":{"errcode":0,"errmsg":"ok","access_token":"moke-token","expires_in":7200},"lifeTime":
|
|
1
|
+
{"data":{"errcode":0,"errmsg":"ok","access_token":"moke-token","expires_in":7200},"lifeTime":1633062831}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"data":{"errcode":0,"errmsg":"ok"},"lifeTime":
|
|
1
|
+
{"data":{"errcode":0,"errmsg":"ok"},"lifeTime":1633062831}
|