Skip to content

Commit 1d2a542

Browse files
committed
better debug messages
1 parent 847ed02 commit 1d2a542

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

backend/sys_stats.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,10 @@ exports.initStats = async function () {
5050
try {
5151
talkgroupStats = JSON.parse(fileContents);
5252
} catch (error) {
53-
console.error("Error parsing JSON data:", error);
53+
console.error("Talkgroup Stats - Error parsing JSON data:", error);
5454
}
55+
} else {
56+
console.error("Talkgroup Stats File not found: " + filePath);
5557
}
5658

5759
// Check if the decodeErrorsFreq.json file exists
@@ -64,9 +66,12 @@ exports.initStats = async function () {
6466
try {
6567
decodeErrorsFreq = JSON.parse(fileContents);
6668
} catch (error) {
67-
console.error("Error parsing JSON data:", error);
69+
console.error("Decode Errors - Error parsing JSON data:", error);
6870
}
71+
} else {
72+
console.error("Decode Errors File not found: " + decodeErrorsFreqPath);
6973
}
74+
7075
/*
7176
for await (const item of SystemStat.find()) {
7277
const obj = item.toObject();

0 commit comments

Comments
 (0)