From d359f5faae124f917843dfd656129af056836b29 Mon Sep 17 00:00:00 2001 From: Luke Berndt Date: Tue, 9 May 2023 21:04:43 -0400 Subject: [PATCH] fixing crashes --- backend/controllers/calls.js | 2 +- backend/sys_stats.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/controllers/calls.js b/backend/controllers/calls.js index 97e6c84..fe70798 100644 --- a/backend/controllers/calls.js +++ b/backend/controllers/calls.js @@ -292,7 +292,7 @@ exports.get_call = async function (req, res) { ); } else { - console.warn("[" + req.params.shortName + "] Error - /:shortName/call/:id Could not find item " + err + " ID: " + objectId); + console.warn("[" + req.params.shortName + "] Error - /:shortName/call/:id Could not find item ID: " + objectId); res.status(404); res.send(JSON.stringify({ success: false, diff --git a/backend/sys_stats.js b/backend/sys_stats.js index 0e89494..3697f49 100644 --- a/backend/sys_stats.js +++ b/backend/sys_stats.js @@ -237,7 +237,7 @@ exports.shiftStats = async function () { tg.totalLen = 0; if (tgHistoryTotal == 0) { // there has been no recent activity on this talkgroup. remove it from the stats. - delete stat[talkgroupNum]; + delete sysTalkgroupStats[talkgroupNum]; } } }