Could be written:

```
node.selectedOpen = layerIds.indexOf(node.idBod) >= 0;
```