Skip to content

Commit

Permalink
fix: set property.max as null if it is 0
Browse files Browse the repository at this point in the history
  • Loading branch information
yashmehrotra committed Jul 4, 2023
1 parent 80a5658 commit fa2bcc5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions templating/js/k8s.js
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,12 @@ k8s = {
pod_mem_limit = fromSI(pod.spec.containers[0].resources.limits.memory || 0)
pod_cpu_limit = fromMillicores(pod.spec.containers[0].resources.limits.cpu || 0)
}
if (pod_mem_limit === 0) {
pod_mem_limit = null
}
if (pod_cpu_limit === 0) {
pod_cpu_limit = null
}

_pod = {
name: pod.metadata.name,
Expand Down

0 comments on commit fa2bcc5

Please sign in to comment.