We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0328055 commit cd9ff6dCopy full SHA for cd9ff6d
lib/client.js
@@ -69,11 +69,15 @@ class Client {
69
}
70
71
message(data) {
72
- const packet = JSON.parse(data);
73
- const [callType, methodName] = Object.keys(packet);
74
- const callId = packet[callType];
75
- const args = packet[methodName];
76
- this.rpc(callId, methodName, args);
+ try {
+ const packet = JSON.parse(data);
+ const [callType, methodName] = Object.keys(packet);
+ const callId = packet[callType];
+ const args = packet[methodName];
77
+ this.rpc(callId, methodName, args);
78
+ } catch (err) {
79
+ application.logger.error(err.message);
80
+ }
81
82
83
async rpc(callId, method, args) {
0 commit comments