mirror of https://github.com/rancher/dashboard.git
Clean up code
Signed-off-by: Francesco Torchia <francesco.torchia@suse.com>
This commit is contained in:
parent
ebc7d81c02
commit
074efb4bc3
|
|
@ -278,13 +278,7 @@ export default {
|
|||
}
|
||||
|
||||
for (const resource of resources) {
|
||||
if (!resource) {
|
||||
return STATES_ENUM.UNHEALTHY;
|
||||
}
|
||||
}
|
||||
|
||||
for (const resource of resources) {
|
||||
if (resource.status.conditions?.find((c) => c.status !== 'True') || resource.metadata.state?.error) {
|
||||
if (!resource || resource.status.conditions?.find((c) => c.status !== 'True') || resource.metadata.state?.error) {
|
||||
return STATES_ENUM.UNHEALTHY;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue