Skip to content

Commit

Permalink
Merge pull request #118 from elad-bar/remove-startup-warning-of-2024-1-0
Browse files Browse the repository at this point in the history
replaced SUPPORT_* constant with SourceType
  • Loading branch information
elad-bar authored Jan 5, 2024
2 parents 5ac3c6f + 520cb9f commit a7e52b6
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 2.0.31

- Replaced soon (2025) to get deprecated SUPPORT\_\* constant with SourceType

## 2.0.30

_Minimum HA Version: 2024.1.0b0_
Expand Down
6 changes: 3 additions & 3 deletions custom_components/edgeos/core/components/device_tracker.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@

import logging

from homeassistant.components.device_tracker import ATTR_SOURCE_TYPE, SOURCE_TYPE_ROUTER
from homeassistant.components.device_tracker import ATTR_SOURCE_TYPE
from homeassistant.components.device_tracker.config_entry import ScannerEntity
from homeassistant.components.device_tracker.const import ATTR_IP, ATTR_MAC
from homeassistant.components.device_tracker.const import ATTR_IP, ATTR_MAC, SourceType
from homeassistant.core import HomeAssistant

from ..helpers.const import DOMAIN_DEVICE_TRACKER
Expand Down Expand Up @@ -38,7 +38,7 @@ def is_connected(self):
@property
def source_type(self):
"""Return the source type."""
return self.entity.attributes.get(ATTR_SOURCE_TYPE, SOURCE_TYPE_ROUTER)
return self.entity.attributes.get(ATTR_SOURCE_TYPE, SourceType.ROUTER)

@staticmethod
def get_component(hass: HomeAssistant, entity: EntityData):
Expand Down
2 changes: 1 addition & 1 deletion custom_components/edgeos/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@
"iot_class": "local_polling",
"issue_tracker": "https://github.com/elad-bar/ha-edgeos/issues",
"requirements": ["aiohttp"],
"version": "2.0.30"
"version": "2.0.31"
}

0 comments on commit a7e52b6

Please sign in to comment.