Skip to content

Commit

Permalink
Library none handling
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew-codechimp committed Dec 13, 2023
1 parent 2219ded commit af0294d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions custom_components/battery_notes/library.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,10 @@ async def get_device_battery_details(
if self._devices is not None:
for device in self._devices:
if (
device["manufacturer"].casefold() == manufacturer.casefold()
and device["model"].casefold() == model.casefold()
str(device["manufacturer"] or "").casefold()
== str(manufacturer or "").casefold()
and str(device["model"] or "").casefold()
== str(model or "").casefold()
):
device_battery_details = DeviceBatteryDetails(
manufacturer=device["manufacturer"],
Expand Down
2 changes: 1 addition & 1 deletion custom_components/battery_notes/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
"integration_type": "device",
"iot_class": "calculated",
"issue_tracker": "https://github.com/andrew-codechimp/ha-battery-notes/issues",
"version": "1.1.0"
"version": "1.1.1"
}

0 comments on commit af0294d

Please sign in to comment.