def time(before=None, after=None, weekday=None):
    """Test if local time condition matches."""
    now = dt_util.now()
    now_time = now.time()

    if before is not None and now_time > before:
        return False

    if after is not None and after < now_time:
        return False

    if weekday is not None:
        now_weekday = WEEKDAYS[now.weekday()]

        if isinstance(weekday, str) and weekday != now_weekday or \
           now_weekday not in weekday:
            return False

    return True
dataset/ETHPy150Open home-assistant/home-assistant/homeassistant/helpers/condition.py/time/swapped operands of `<`