Fix docstrings (#15770)

This commit is contained in:
Fabian Affolter 2018-07-31 21:39:37 +02:00 committed by Daniel Høyer Iversen
parent 95da41aa15
commit a11c2a0bd8
2 changed files with 8 additions and 7 deletions

View File

@ -2,9 +2,10 @@
from homeassistant.core import callback
from homeassistant.loader import bind_hass
from .const import STEPS, STEP_USER, DOMAIN
from .const import DOMAIN, STEP_USER, STEPS
DEPENDENCIES = ['http']
STORAGE_KEY = DOMAIN
STORAGE_VERSION = 1
@ -21,7 +22,7 @@ def async_is_onboarded(hass):
async def async_setup(hass, config):
"""Set up the onboard component."""
"""Set up the onboarding component."""
store = hass.helpers.storage.Store(STORAGE_VERSION, STORAGE_KEY)
data = await store.async_load()

View File

@ -3,21 +3,21 @@ import asyncio
import voluptuous as vol
from homeassistant.core import callback
from homeassistant.components.http.view import HomeAssistantView
from homeassistant.components.http.data_validator import RequestDataValidator
from homeassistant.components.http.view import HomeAssistantView
from homeassistant.core import callback
from .const import DOMAIN, STEPS, STEP_USER
from .const import DOMAIN, STEP_USER, STEPS
async def async_setup(hass, data, store):
"""Setup onboarding."""
"""Set up the onboarding view."""
hass.http.register_view(OnboardingView(data, store))
hass.http.register_view(UserOnboardingView(data, store))
class OnboardingView(HomeAssistantView):
"""Returns the onboarding status."""
"""Return the onboarding status."""
requires_auth = False
url = '/api/onboarding'