This commit is contained in:
rmoren97 2026-02-07 15:39:32 -08:00
parent ca43e4aee8
commit 012388c288

View File

@ -238,7 +238,7 @@ export default function ServerDetailPage() {
data={cpuHistory} data={cpuHistory}
maxDataPoints={MAX_STATS_POINTS} maxDataPoints={MAX_STATS_POINTS}
label="CPU Usage" label="CPU Usage"
value={currentStats ? `${currentStats.cpu.toFixed(1)}%` : '—'} value={currentStats?.cpu != null ? `${currentStats.cpu.toFixed(1)}%` : '—'}
color="cyan" color="cyan"
maxY={100} maxY={100}
unit="%" unit="%"
@ -247,8 +247,8 @@ export default function ServerDetailPage() {
data={memHistory} data={memHistory}
maxDataPoints={MAX_STATS_POINTS} maxDataPoints={MAX_STATS_POINTS}
label="Memory Usage" label="Memory Usage"
value={currentStats ? formatBytes(currentStats.memUsed) : '—'} value={currentStats?.memUsed != null ? formatBytes(currentStats.memUsed) : '—'}
subValue={currentStats ? `/ ${formatBytes(currentStats.memLimit)}` : undefined} subValue={currentStats?.memLimit != null ? `/ ${formatBytes(currentStats.memLimit)}` : undefined}
color="emerald" color="emerald"
maxY={currentStats?.memLimit || server.memory.max * 1024 * 1024} maxY={currentStats?.memLimit || server.memory.max * 1024 * 1024}
unit="" unit=""