Fix tcp typing, fixing CI (#50965)

This commit is contained in:
Franck Nijhof 2021-05-22 19:16:11 +02:00 committed by GitHub
parent e64b5afa58
commit 3c8707f912
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -29,7 +29,7 @@ from homeassistant.exceptions import TemplateError
import homeassistant.helpers.config_validation as cv
from homeassistant.helpers.entity_platform import AddEntitiesCallback
from homeassistant.helpers.template import Template
from homeassistant.helpers.typing import ConfigType
from homeassistant.helpers.typing import ConfigType, StateType
from .const import (
CONF_BUFFER_SIZE,
@ -112,7 +112,7 @@ class TcpSensor(SensorEntity):
return self._config[CONF_NAME]
@property
def state(self) -> str | None:
def state(self) -> StateType:
"""Return the state of the device."""
return self._state