Skip to content

Commit

Permalink
add json decode quirk for xiaomi e10
Browse files Browse the repository at this point in the history
  • Loading branch information
kolos authored Oct 7, 2023
1 parent 79d2685 commit e96e70f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions miio/protocol.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,10 @@ def _decode(self, obj, context, path) -> Union[Dict, bytes]:
lambda decrypted_bytes: decrypted_bytes.replace(
b'"value":00', b'"value":0'
),
# fix double commas for xiaomi.vacuum.b112, fw: 2.2.4_0049
lambda decrypted_bytes: decrypted_bytes.replace(
b',,', b','
),
]

for i, quirk in enumerate(decrypted_quirks):
Expand Down

0 comments on commit e96e70f

Please sign in to comment.