mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Use core constants for uvc (#46538)
This commit is contained in:
parent
aa061e5818
commit
f1c792b4c8
@ -9,7 +9,7 @@ from uvcclient import camera as uvc_camera, nvr
|
|||||||
import voluptuous as vol
|
import voluptuous as vol
|
||||||
|
|
||||||
from homeassistant.components.camera import PLATFORM_SCHEMA, SUPPORT_STREAM, Camera
|
from homeassistant.components.camera import PLATFORM_SCHEMA, SUPPORT_STREAM, Camera
|
||||||
from homeassistant.const import CONF_PORT, CONF_SSL
|
from homeassistant.const import CONF_PASSWORD, CONF_PORT, CONF_SSL
|
||||||
from homeassistant.exceptions import PlatformNotReady
|
from homeassistant.exceptions import PlatformNotReady
|
||||||
import homeassistant.helpers.config_validation as cv
|
import homeassistant.helpers.config_validation as cv
|
||||||
|
|
||||||
@ -17,7 +17,6 @@ _LOGGER = logging.getLogger(__name__)
|
|||||||
|
|
||||||
CONF_NVR = "nvr"
|
CONF_NVR = "nvr"
|
||||||
CONF_KEY = "key"
|
CONF_KEY = "key"
|
||||||
CONF_PASSWORD = "password"
|
|
||||||
|
|
||||||
DEFAULT_PASSWORD = "ubnt"
|
DEFAULT_PASSWORD = "ubnt"
|
||||||
DEFAULT_PORT = 7080
|
DEFAULT_PORT = 7080
|
||||||
@ -197,7 +196,6 @@ class UnifiVideoCamera(Camera):
|
|||||||
|
|
||||||
def camera_image(self):
|
def camera_image(self):
|
||||||
"""Return the image of this camera."""
|
"""Return the image of this camera."""
|
||||||
|
|
||||||
if not self._camera:
|
if not self._camera:
|
||||||
if not self._login():
|
if not self._login():
|
||||||
return
|
return
|
||||||
|
Loading…
x
Reference in New Issue
Block a user