Skip to content

Commit

Permalink
files reformatted
Browse files Browse the repository at this point in the history
  • Loading branch information
Ludy87 committed Jan 17, 2025
1 parent 6cf0df5 commit f037685
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion custom_components/xplora_watch/coordinator.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ def __init__(self, hass: HomeAssistant, entry: ConfigEntry) -> None:
super().__init__(
hass,
_LOGGER,
name=f'{DOMAIN}-{entry.data[CONF_PHONENUMBER][5:] if CONF_EMAIL not in entry.data else ""}',
name=f"{DOMAIN}-{entry.data[CONF_PHONENUMBER][5:] if CONF_EMAIL not in entry.data else ''}",
update_method=self.async_update_xplora_data,
update_interval=_update_interval,
)
Expand Down
2 changes: 1 addition & 1 deletion custom_components/xplora_watch/device_tracker.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def __init__(
)

self._attr_unique_id = (
f'{ward.get(CONF_NAME)}_{ATTR_WATCH}_safezone_{safezone["vendorId"]}_{wuid}_{coordinator.user_id}'.replace(
f"{ward.get(CONF_NAME)}_{ATTR_WATCH}_safezone_{safezone['vendorId']}_{wuid}_{coordinator.user_id}".replace(
" ", "_"
)
.replace("-", "_")
Expand Down
8 changes: 4 additions & 4 deletions custom_components/xplora_watch/switch.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,13 +105,13 @@ def __init__(
self._alarm = alarm

self._attr_name: str = (
f'{ward.get(CONF_NAME)} {ATTR_WATCH} {description.key} {alarm["start"]} ({coordinator.username})'.replace(
f"{ward.get(CONF_NAME)} {ATTR_WATCH} {description.key} {alarm['start']} ({coordinator.username})".replace(
"_", " "
).title()
)

self._attr_unique_id = (
f'{ward.get(CONF_NAME)}_{ATTR_WATCH}_{description.key}_{alarm["vendorId"]}_{wuid}_{coordinator.user_id}'.replace(
f"{ward.get(CONF_NAME)}_{ATTR_WATCH}_{description.key}_{alarm['vendorId']}_{wuid}_{coordinator.user_id}".replace(
" ", "_"
)
.replace("-", "_")
Expand Down Expand Up @@ -201,12 +201,12 @@ def __init__(

self._silent = silent

self._attr_name: str = f'{ward.get(CONF_NAME)} {ATTR_WATCH} {description.key} {silent["start"]}-{silent["end"]} ({coordinator.username})'.replace( # noqa: E501
self._attr_name: str = f"{ward.get(CONF_NAME)} {ATTR_WATCH} {description.key} {silent['start']}-{silent['end']} ({coordinator.username})".replace( # noqa: E501
"_", " "
).title()

self._attr_unique_id = (
f'{ward.get(CONF_NAME)}_{ATTR_WATCH}_{description.key}_{silent["vendorId"]}_{wuid}_{coordinator.user_id}'.replace(
f"{ward.get(CONF_NAME)}_{ATTR_WATCH}_{description.key}_{silent['vendorId']}_{wuid}_{coordinator.user_id}".replace(
" ", "_"
)
.replace("-", "_")
Expand Down

0 comments on commit f037685

Please sign in to comment.