Skip to content

Commit 2867301

Browse files
learn-morefrenck
andauthored
Simplify sun condition schema by re-using an existing type (home-assistant#161894)
Co-authored-by: Franck Nijhof <git@frenck.dev>
1 parent 95a5825 commit 2867301

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

homeassistant/components/sun/condition.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,7 @@
2626
_OPTIONS_SCHEMA_DICT: dict[vol.Marker, Any] = {
2727
vol.Optional("before"): cv.sun_event,
2828
vol.Optional("before_offset"): cv.time_period,
29-
vol.Optional("after"): vol.All(
30-
vol.Lower, vol.Any(SUN_EVENT_SUNSET, SUN_EVENT_SUNRISE)
31-
),
29+
vol.Optional("after"): cv.sun_event,
3230
vol.Optional("after_offset"): cv.time_period,
3331
}
3432

0 commit comments

Comments
 (0)