Skip to content

Commit

Permalink
Fix get attr type for raw zigbee commands
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexxIT committed Mar 1, 2024
1 parent 1616579 commit 85518a8
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ def get_attr(attributes: Dict[int, ZCLAttributeDef], attr: Union[str, int]) -> i

def get_attr_type(attributes: Dict[int, ZCLAttributeDef], attr: str) -> (int, int):
attr = next(v for v in attributes.values() if v.name == attr)
typeid = next(k for k, v in DATA_TYPES.items() if v[1] == attr.type)
typeid = next(k for k, v in DATA_TYPES.items() if issubclass(attr.type, v[1]))
return attr.id, typeid


Expand Down

0 comments on commit 85518a8

Please sign in to comment.