Skip to content

Commit

Permalink
Fix gen property
Browse files Browse the repository at this point in the history
  • Loading branch information
bieniu committed Dec 1, 2023
1 parent f206619 commit babc7a4
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions aioshelly/rpc_device/device.py
Expand Up @@ -373,8 +373,11 @@ def shelly(self) -> dict[str, Any]:

@property
def gen(self) -> int:
"""Device generation: GEN2 - RPC."""
return 2
"""Device generation: GEN2/3 - RPC."""
if self._shelly is None:
raise NotInitialized

return cast(int, self._shelly["gen"])

@property
def firmware_version(self) -> str:
Expand Down

0 comments on commit babc7a4

Please sign in to comment.