Skip to content

Commit

Permalink
Merge pull request #11 from topic2k/dev
Browse files Browse the repository at this point in the history
update due to webpage changes
  • Loading branch information
vigonotion authored Jan 10, 2022
2 parents 3242037 + fc7462b commit 7f4bf0c
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
4 changes: 2 additions & 2 deletions custom_components/stadtreinigung_hamburg/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"@vigonotion"
],
"requirements": [
"stadtreinigung-hamburg==0.1.2"
"stadtreinigung-hamburg==0.3.0"
],
"config_flow": true
}
}
15 changes: 9 additions & 6 deletions custom_components/stadtreinigung_hamburg/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@
)

sensors = [
"grüne Biotonne",
"schwarze Restmülltonne",
"gelbe Wertstofftonne/-sack",
"blaue Papiertonne",
"Grüne Biotonne",
"Schwarze Restmülltonne",
"Gelbe Wertstofftonne/-sack",
"Blaue Papiertonne",
"Weihnachtsbäume",
"Laubsäcke",
]
Expand Down Expand Up @@ -102,8 +102,11 @@ def device_class(self) -> Optional[str]:
return DEVICE_CLASS_TIMESTAMP

@property
def device_state_attributes(self):
return {ATTR_LAST_UPDATE: self._last_update}
def extra_state_attributes(self):
"""Return the state attributes."""
return {
ATTR_LAST_UPDATE: self._last_update,
}

@property
def unique_id(self):
Expand Down

0 comments on commit 7f4bf0c

Please sign in to comment.