Studio: cleanup 'null'-layers before generating errors

This commit is contained in:
Pieter Vander Vennet 2024-04-27 23:43:39 +02:00
parent d2e7bac775
commit 181965efd9
2 changed files with 11 additions and 0 deletions

View file

@ -1649,4 +1649,12 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be
}
return n + Utils._metrixPrefixes[index]
}
static NoNullInplace(layers: any[]):void {
for (let i = layers.length - 1; i >= 0; i--) {
if(layers[i] === null || layers[i] === undefined){
layers.splice(i, 1)
}
}
}
}