From a87cab400c34a2377781e8bfff444d01e6951ce8 Mon Sep 17 00:00:00 2001 From: "Jason R. Coombs" Date: Mon, 8 Jul 2024 07:15:32 -0400 Subject: [PATCH] Inline the initialization. --- jaraco/abode/devices/base.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/jaraco/abode/devices/base.py b/jaraco/abode/devices/base.py index d60bb23..996e28b 100644 --- a/jaraco/abode/devices/base.py +++ b/jaraco/abode/devices/base.py @@ -133,9 +133,7 @@ def new(cls, state, client): except KeyError as exc: raise jaraco.abode.Exception(ERROR.UNABLE_TO_MAP_DEVICE) from exc - init_cls = cls.resolve_class(type_tag) - spec_cls = init_cls.specialize(state) - return spec_cls(state, client) + return cls.resolve_class(type_tag).specialize(state)(state, client) @property def generic_type(self):