Merge pull request #997 from robintown/telemetry-crash

Fix a crash when adding call events to telemetry
This commit is contained in:
Robin 2023-04-12 09:26:03 -04:00 committed by GitHub
commit d211d27817
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -74,7 +74,7 @@ function flattenVoipEventRecursive(
);
for (const [k, v] of Object.entries(obj)) {
if (["string", "number", "boolean"].includes(typeof v)) {
if (["string", "number", "boolean"].includes(typeof v) || v === null) {
flatObject[prefix + k] = v;
} else if (typeof v === "object") {
flattenVoipEventRecursive(