Adhere to scan_interval in platforms when setup via config entry (#14969)

This commit is contained in:
Paulus Schoutsen 2018-06-15 10:59:13 -04:00 committed by Pascal Vizeli
parent d6d685a483
commit 1128104281
3 changed files with 11 additions and 3 deletions

View file

@ -108,7 +108,8 @@ class EntityComponent(object):
raise ValueError('Config entry has already been setup!')
self._platforms[key] = self._async_init_entity_platform(
platform_type, platform
platform_type, platform,
scan_interval=getattr(platform, 'SCAN_INTERVAL', None),
)
return await self._platforms[key].async_setup_entry(config_entry)