Add more debugging statements

This commit is contained in:
D. Berge
2023-10-04 14:50:12 +02:00
parent 2e11c574c2
commit 7b6b81dbc5

View File

@@ -267,6 +267,7 @@ class ReportLineChangeTime {
} }
async run (data) { async run (data) {
DEBUG("Seen", data);
if (!data || data.channel !== "event") { if (!data || data.channel !== "event") {
return; return;
} }
@@ -285,10 +286,12 @@ class ReportLineChangeTime {
if (this.queue.length < ReportLineChangeTime.MAX_QUEUE_SIZE) { if (this.queue.length < ReportLineChangeTime.MAX_QUEUE_SIZE) {
this.queue.push({ const item = {
...data.payload, ...structuredClone(data.payload),
isPending: this.queue.length, isPending: this.queue.length,
}); };
DEBUG("Queueing", item);
this.queue.push(item);
} else { } else {
ALERT("ReportLineChangeTime queue full at", this.queue.length); ALERT("ReportLineChangeTime queue full at", this.queue.length);