Do not fail MQTT setup if camera's configured via yaml can't be validated (#102302)

Add camera
This commit is contained in:
Jan Bouwhuis 2023-10-19 18:17:06 +02:00 committed by GitHub
parent 651b725cc0
commit fb984b5218
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 21 deletions

View file

@ -16,7 +16,6 @@ from homeassistant.helpers import config_validation as cv
from . import (
button as button_platform,
camera as camera_platform,
climate as climate_platform,
cover as cover_platform,
device_tracker as device_tracker_platform,
@ -59,10 +58,7 @@ CONFIG_SCHEMA_BASE = vol.Schema(
cv.ensure_list,
[button_platform.PLATFORM_SCHEMA_MODERN], # type: ignore[has-type]
),
Platform.CAMERA.value: vol.All(
cv.ensure_list,
[camera_platform.PLATFORM_SCHEMA_MODERN], # type: ignore[has-type]
),
Platform.CAMERA.value: vol.All(cv.ensure_list, [dict]),
Platform.CLIMATE.value: vol.All(
cv.ensure_list,
[climate_platform.PLATFORM_SCHEMA_MODERN], # type: ignore[has-type]