diff --git a/src/components/Widgets/GlCompactMetrics.vue b/src/components/Widgets/GlCompactMetrics.vue index 0c8517eb..8030d44e 100644 --- a/src/components/Widgets/GlCompactMetrics.vue +++ b/src/components/Widgets/GlCompactMetrics.vue @@ -325,7 +325,7 @@ export default { }, formatBytes(bytes) { - if (!bytes || Number.isNaN(bytes)) return '0 B'; + if (bytes == null || isNaN(bytes)) return '0 B'; const k = 1024; const sizes = ['B', 'KB', 'MB', 'GB', 'TB']; const i = Math.floor(Math.log(bytes) / Math.log(k));