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 ac70bbc commit d481a1eCopy full SHA for d481a1e
lib/OBSWebSocket.js
@@ -29,6 +29,10 @@ class OBSWebSocket extends Socket {
29
rejectReason = Status.REQUEST_TYPE_NOT_SPECIFIED;
30
}
31
32
+ if (args && (typeof args !== 'object' || args === null || Array.isArray(args))) {
33
+ rejectReason = Status.ARGS_NOT_OBJECT;
34
+ }
35
+
36
if (!this._connected) {
37
rejectReason = Status.NOT_CONNECTED;
38
lib/Status.js
@@ -19,6 +19,10 @@ module.exports = {
19
status: 'error',
20
description: 'A Request Type was not specified.'
21
},
22
+ ARGS_NOT_OBJECT: {
23
+ status: 'error',
24
+ description: 'The supplied argments parameter is not an object.'
25
+ },
26
27
init() {
28
for (const key in this) {
0 commit comments