Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
Bram van Dartel committed Feb 8, 2021
1 parent 1c0a848 commit a01ec3b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion custom_components/afvalwijzer/const/const.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
STARTUP_MESSAGE = """
-------------------------------------------------------------------
Afvalwijzer
Version: 5.3.1
Version: 5.3.2
This is a custom integration!
If you have any issues with this you need to open an issue here:
"https://github.com/xirixiz/homeassistant-afvalwijzer/issues"
Expand Down
6 changes: 6 additions & 0 deletions custom_components/afvalwijzer/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
CONF_POSTAL_CODE,
CONF_PROVIDER,
CONF_STREET_NUMBER,
CONF_EXCLUDE_LIST,
CONF_SUFFIX,
MIN_TIME_BETWEEN_UPDATES,
PARALLEL_UPDATES,
Expand All @@ -43,6 +44,7 @@
vol.Optional(CONF_INCLUDE_DATE_TODAY.strip(), default="false"): cv.string,
vol.Optional(CONF_DEFAULT_LABEL.strip(), default="Geen"): cv.string,
vol.Optional(CONF_ID.strip().lower(), default=""): cv.string,
vol.Optional(CONF_EXCLUDE_LIST.strip().lower(), default=""): cv.string,
}
)

Expand All @@ -56,6 +58,7 @@ async def async_setup_platform(hass, config, async_add_entities, discovery_info=
suffix = config.get(CONF_SUFFIX)
include_date_today = config.get(CONF_INCLUDE_DATE_TODAY)
default_label = config.get(CONF_DEFAULT_LABEL)
exclude_list = config.get(CONF_EXCLUDE_LIST)

_LOGGER.debug("Afvalwijzer provider = %s", provider)
_LOGGER.debug("Afvalwijzer zipcode = %s", postal_code)
Expand All @@ -71,6 +74,7 @@ async def async_setup_platform(hass, config, async_add_entities, discovery_info=
suffix,
include_date_today,
default_label,
exclude_list,
)
)
except ValueError as err:
Expand Down Expand Up @@ -113,6 +117,7 @@ def update(self):
suffix = self.config.get(CONF_SUFFIX)
include_date_today = self.config.get(CONF_INCLUDE_DATE_TODAY)
default_label = self.config.get(CONF_DEFAULT_LABEL)
exclude_list = self.config.get(CONF_EXCLUDE_LIST)

try:
afvalwijzer = AfvalWijzer(
Expand All @@ -122,6 +127,7 @@ def update(self):
suffix,
include_date_today,
default_label,
exclude_list,
)
except ValueError as err:
_LOGGER.error("Check afvalwijzer platform settings %s", err.args)
Expand Down

0 comments on commit a01ec3b

Please sign in to comment.