Merge branch 'master' into dev

This commit is contained in:
Nick O'Leary
2020-11-18 16:36:56 +00:00
25 changed files with 247 additions and 55 deletions

View File

@@ -774,6 +774,12 @@ function encodeObject(msg,opts) {
data: value.toString()
}
}
} else if (typeof value === 'bigint') {
value = {
__enc__: true,
type: 'bigint',
data: value.toString()
}
} else if (value && value.constructor) {
if (value.type === "Buffer") {
value.__enc__ = true;
@@ -808,6 +814,13 @@ function encodeObject(msg,opts) {
} else if (msgType === "number") {
msg.format = "number";
msg.msg = msg.msg.toString();
} else if (msgType === "bigint") {
msg.format = "bigint";
msg.msg = {
__enc__: true,
type: 'bigint',
data: msg.msg.toString()
};
} else if (msg.msg === null || msgType === "undefined") {
msg.format = (msg.msg === null)?"null":"undefined";
msg.msg = "(undefined)";

View File

@@ -20,7 +20,7 @@
"json-stringify-safe": "5.0.1",
"jsonata": "1.8.4",
"lodash.clonedeep": "^4.5.0",
"moment-timezone": "^0.5.31",
"moment-timezone": "0.5.32",
"when": "3.7.8"
}
}