diff --git a/custom_components/ohme/utils.py b/custom_components/ohme/utils.py index 1648727..dc1776d 100644 --- a/custom_components/ohme/utils.py +++ b/custom_components/ohme/utils.py @@ -164,6 +164,7 @@ def charge_graph_in_slot(charge_start, points, skip_format=False): def time_next_occurs(hour, minute): """Find when this time next occurs.""" + current = datetime.now() target = current.replace(hour=hour, minute=minute, second=0, microsecond=0) if target <= datetime.now(): target = target + timedelta(days=1)