Move imports in keyboard component (#27791)

pull/27797/head
Quentame 2019-10-17 14:58:56 +02:00 committed by Pascal Vizeli
parent e54f5102aa
commit 35e0acf0a5
1 changed files with 2 additions and 2 deletions

View File

@ -1,4 +1,5 @@
"""Support to emulate keyboard presses on host machine."""
from pykeyboard import PyKeyboard # pylint: disable=import-error
import voluptuous as vol
from homeassistant.const import (
@ -17,9 +18,8 @@ TAP_KEY_SCHEMA = vol.Schema({})
def setup(hass, config):
"""Listen for keyboard events."""
import pykeyboard # pylint: disable=import-error
keyboard = pykeyboard.PyKeyboard()
keyboard = PyKeyboard()
keyboard.special_key_assignment()
hass.services.register(