mirror of
https://github.com/skooner-k8s/skooner.git
synced 2026-08-24 04:16:18 +00:00
Merge pull request #145 from hodovani/patch-1
Remove comparing a string and a number
This commit is contained in:
@@ -151,7 +151,7 @@ function percent(node: Node, used: number | string | null, resource: ResourceTyp
|
||||
const result = unparser(used);
|
||||
|
||||
const available = getNodeResourcesAvailable(node, resource);
|
||||
const displayPercent = available ? _.round(Number(used) / available * 100, 1) : '';
|
||||
const displayPercent = available ? _.round(Number(used) / available * 100, 1) : 0;
|
||||
const className = displayPercent >= 85 ? 'contentPanel_warn' : undefined;
|
||||
|
||||
return (
|
||||
|
||||
Reference in New Issue
Block a user