mirror of
https://github.com/DigiLive/mushroom-strategy.git
synced 2025-08-04 20:14:28 +02:00
add condition
This commit is contained in:
22
dist/mushroom-strategy.js
vendored
22
dist/mushroom-strategy.js
vendored
@@ -361,15 +361,19 @@ class MushroomStrategy {
|
||||
} else
|
||||
{
|
||||
const weatherEntity = entities.find(entity => entity.entity_id.startsWith("weather.") && entity.disabled_by == null)
|
||||
chips.push
|
||||
(
|
||||
{
|
||||
type: "weather",
|
||||
entity: weatherEntity.entity_id,
|
||||
show_temperature: true,
|
||||
show_conditions: true
|
||||
}
|
||||
)
|
||||
if (weatherEntity != null)
|
||||
{
|
||||
chips.push
|
||||
(
|
||||
{
|
||||
type: "weather",
|
||||
entity: weatherEntity.entity_id,
|
||||
show_temperature: true,
|
||||
show_conditions: true
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user