1
mirror of https://github.com/home-assistant/core synced 2024-07-27 18:58:57 +02:00

Remove incorrect use of iscoroutinefunction from duckdns (#58585)

This commit is contained in:
Erik Montnemery 2021-10-28 11:05:02 +02:00 committed by GitHub
parent e99bef7b6e
commit 7a728997bb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,5 +1,4 @@
"""Integrate with DuckDNS."""
from asyncio import iscoroutinefunction
from datetime import timedelta
import logging
@ -102,10 +101,6 @@ async def _update_duckdns(session, domain, token, *, txt=_SENTINEL, clear=False)
@bind_hass
def async_track_time_interval_backoff(hass, action, intervals) -> CALLBACK_TYPE:
"""Add a listener that fires repetitively at every timedelta interval."""
if not iscoroutinefunction:
_LOGGER.error("Action needs to be a coroutine and return True/False")
return
if not isinstance(intervals, (list, tuple)):
intervals = (intervals,)
remove = None