Improve string formatting v3 (#33667)

* Improve string formatting v3

* Address review comment
This commit is contained in:
springstan 2020-04-05 01:32:58 +02:00 committed by GitHub
parent bf1b408038
commit c20a965eda
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
24 changed files with 32 additions and 37 deletions

View file

@ -139,7 +139,7 @@ def async_add_entities_config(hass, config, async_add_entities):
"""Set up climate for KNX platform configured within platform."""
climate_mode = XknxClimateMode(
hass.data[DATA_KNX].xknx,
name=config[CONF_NAME] + " Mode",
name=f"{config[CONF_NAME]} Mode",
group_address_operation_mode=config.get(CONF_OPERATION_MODE_ADDRESS),
group_address_operation_mode_state=config.get(
CONF_OPERATION_MODE_STATE_ADDRESS