Move imports in mobile_app component (#28027)

This commit is contained in:
Diefferson Koderer Môro authored and Fabian Affolter committed 2019-10-21 10:05:41 +02:00
1 parent 206f8cef5c
commit 3e9d28f28a
11 files changed
+24 -35

No files matched your search

@@ -1,9 +1,11 @@
"""Helpers for mobile_app."""
import logging
import json
import logging
from typing import Callable, Dict, Tuple
from aiohttp.web import json_response, Response
from aiohttp.web import Response, json_response
from nacl.encoding import Base64Encoder
from nacl.secret import SecretBox
from homeassistant.core import Context
from homeassistant.helpers.json import JSONEncoder
@@ -13,8 +15,8 @@ from .const import (
ATTR_APP_DATA,
ATTR_APP_ID,
ATTR_APP_NAME,
ATTR_DEVICE_ID,
ATTR_APP_VERSION,
ATTR_DEVICE_ID,
ATTR_DEVICE_NAME,
ATTR_MANUFACTURER,
ATTR_MODEL,
@@ -36,8 +38,6 @@ def setup_decrypt() -> Tuple[int, Callable]:
Async friendly.
"""
from nacl.secret import SecretBox
from nacl.encoding import Base64Encoder
def decrypt(ciphertext, key):
"""Decrypt ciphertext using key."""
@@ -51,8 +51,6 @@ def setup_encrypt() -> Tuple[int, Callable]:
Async friendly.
"""
from nacl.secret import SecretBox
from nacl.encoding import Base64Encoder
def encrypt(ciphertext, key):
"""Encrypt ciphertext using key."""