Move imports in rfxtrx component (#27549)
This commit is contained in:
1 parent
3873a1b070
commit
40e5beb0ed
9 files changed
+11
-32
No files matched your search
@@ -1,6 +1,6 @@
|
||||
"""Support for RFXtrx switches."""
|
||||
import logging
|
||||
|
||||
import RFXtrx as rfxtrxmod
|
||||
import voluptuous as vol
|
||||
|
||||
from homeassistant.components import rfxtrx
|
||||
@@ -38,8 +38,6 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend(
|
||||
|
||||
def setup_platform(hass, config, add_entities_callback, discovery_info=None):
|
||||
"""Set up the RFXtrx platform."""
|
||||
import RFXtrx as rfxtrxmod
|
||||
|
||||
# Add switch from config file
|
||||
switches = rfxtrx.get_devices_from_config(config, RfxtrxSwitch)
|
||||
add_entities_callback(switches)
|
||||
|
||||
Reference in new issue
Block a user