@peopl-health/nexus 5.57.0-dev.9357 → 5.57.0-dev.9378
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -240,17 +240,17 @@ async function sweepColdUnansweredInbound({
|
|
|
240
240
|
}
|
|
241
241
|
}
|
|
242
242
|
|
|
243
|
-
if (!waiting.length) return { waiting: 0, alerted: 0 };
|
|
244
|
-
|
|
245
243
|
waiting.sort((a, b) => new Date(a.inbound.createdAt) - new Date(b.inbound.createdAt));
|
|
246
244
|
|
|
247
245
|
if (mode === 'report') {
|
|
248
|
-
logger.error('[inboundRecovery]
|
|
249
|
-
waiting: waiting.length, oldest: waiting[0]
|
|
246
|
+
logger.error('[inboundRecovery] counted the patients waiting far longer than the live pass looks', {
|
|
247
|
+
waiting: waiting.length, oldest: waiting[0]?.inbound?.createdAt ?? null, atCeiling, mode,
|
|
250
248
|
});
|
|
251
249
|
return { waiting: waiting.length, alerted: 0 };
|
|
252
250
|
}
|
|
253
251
|
|
|
252
|
+
if (!waiting.length) return { waiting: 0, alerted: 0 };
|
|
253
|
+
|
|
254
254
|
let alerted = 0;
|
|
255
255
|
for (const { code, inbound } of waiting) {
|
|
256
256
|
if (alerted >= COLD_TICKETS_PER_PASS) break;
|