Skip to content

Commit

Permalink
fix update coordinator for tracker
Browse files Browse the repository at this point in the history
  • Loading branch information
firstof9 committed Apr 17, 2023
1 parent 87c12bb commit 6d0631d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion custom_components/nws_alerts/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ async def _async_update_data(self):
async def _get_tracker_gps(self):
"""Return device tracker GPS data."""
tracker = self.config[CONF_TRACKER]
entity = self.hass.get(tracker)
entity = self.hass.states.get(tracker)
if entity and "source_type" in entity.attributes:
return f"{entity.attributes['latitude']},{entity.attributes['longitude']}"
return None
Expand Down

0 comments on commit 6d0631d

Please sign in to comment.