mirror of https://github.com/home-assistant/core
Fix proxy camera conversion with PNG Alpha(RGBA) (#40446)
This commit is contained in:
parent
f837da6fe3
commit
1ed8e41e90
|
@ -77,6 +77,8 @@ def _precheck_image(image, opts):
|
|||
if imgfmt not in ("PNG", "JPEG"):
|
||||
_LOGGER.warning("Image is of unsupported type: %s", imgfmt)
|
||||
raise ValueError()
|
||||
if not img.mode == "RGB":
|
||||
img = img.convert("RGB")
|
||||
return img
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue