1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-23 20:39:01 +00:00

Set placeholders in homekit config flow title (#23311)

This commit is contained in:
Jc2k
2019-04-23 05:32:39 +01:00
committed by Paulus Schoutsen
parent ee88433fb1
commit baeb3cddc6
3 changed files with 68 additions and 41 deletions

View File

@@ -130,6 +130,11 @@ class HomekitControllerFlowHandler(config_entries.ConfigFlow):
status_flags = int(properties['sf'])
paired = not status_flags & 0x01
# pylint: disable=unsupported-assignment-operation
self.context['title_placeholders'] = {
'name': discovery_info['name'],
}
# The configuration number increases every time the characteristic map
# needs updating. Some devices use a slightly off-spec name so handle
# both cases.