fix: hide usage errors in status

This commit is contained in:
Peter Steinberger
2026-01-23 19:42:55 +00:00
parent f07c39b265
commit c63144ab14

View File

@@ -39,7 +39,7 @@ export function formatUsageWindowSummary(
snapshot: ProviderUsageSnapshot,
opts?: { now?: number; maxWindows?: number; includeResets?: boolean },
): string | null {
if (snapshot.error) return `error: ${snapshot.error}`;
if (snapshot.error) return null;
if (snapshot.windows.length === 0) return null;
const now = opts?.now ?? Date.now();
const maxWindows =