1
0
mirror of https://github.com/home-assistant/frontend.git synced 2025-12-19 18:28:42 +00:00

Check if entities is an array (#5193)

This commit is contained in:
Bram Kragten
2020-03-13 17:48:49 +01:00
committed by GitHub
parent 330eb0957b
commit 0c3c007faf

View File

@@ -44,7 +44,7 @@ const addEntities = (entities: Set<string>, obj) => {
if (obj.entity) {
addEntityId(entities, obj.entity);
}
if (obj.entities) {
if (obj.entities && Array.isArray(obj.entities)) {
obj.entities.forEach((entity) => addEntityId(entities, entity));
}
if (obj.card) {