Skip to content

Commit

Permalink
fix: fix unit convert attribute error
Browse files Browse the repository at this point in the history
  • Loading branch information
topsworld committed Dec 23, 2024
1 parent 9af59e2 commit 25f8960
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion custom_components/xiaomi_home/miot/miot_device.py
Original file line number Diff line number Diff line change
Expand Up @@ -628,7 +628,7 @@ def unit_convert(self, spec_unit: str) -> Optional[str]:
# pylint: disable=import-outside-toplevel
from homeassistant.const import UnitOfConductivity
unit_map['μS/cm'] = UnitOfConductivity.MICROSIEMENS_PER_CM
except ImportError:
except Exception: # pylint: disable=broad-except
unit_map['μS/cm'] = 'μS/cm'

return unit_map.get(spec_unit, None)
Expand Down

0 comments on commit 25f8960

Please sign in to comment.