Update online status calculation to check if failure rate is below 50%

This commit is contained in:
headlessdev 2025-04-15 14:30:29 +02:00
parent a3b47bd314
commit 871ab74576

View File

@ -136,7 +136,7 @@ export async function POST(request: NextRequest) {
return { return {
timestamp: intervalKey, timestamp: intervalKey,
missing: !stats, missing: !stats,
online: stats ? stats.failed < 3 : null online: stats ? (stats.failed / stats.total) <= 0.5 : null
}; };
}); });