diff --git a/aiocraft/traits/callbacks.py b/aiocraft/traits/callbacks.py index 91745ef..14ad8f3 100644 --- a/aiocraft/traits/callbacks.py +++ b/aiocraft/traits/callbacks.py @@ -17,7 +17,7 @@ class CallbacksHolder: self._tasks = {} def callback_keys(self, filter:Type = None) -> Set[Any]: - return set(x for x in self._callbacks.keys() if not filter or isinstance(x, filter)) + return set(x for x in self._callbacks.keys() if not filter or issubclass(x, filter)) def register(self, key:Any, callback:Callable): if key not in self._callbacks: