handle case when available_runtimes is null

This commit is contained in:
dcore94 2022-11-23 17:12:10 +01:00
parent b337fb2075
commit e2ee020ec5
1 changed files with 1 additions and 0 deletions

View File

@ -166,6 +166,7 @@ class CCPInfrastructureList extends HTMLElement{
showDeployableRuntimes(infra){
const alreadydeployed = infra.runtimes.map(r=>r["descriptor-id"])
infra.available_runtimes = infra.available_runtimes ? infra.available_runtimes : []
const options = infra.available_runtimes.filter(r=>{
return infra.type === r.type && alreadydeployed.indexOf(r.id) === -1
}).map(r=>{