Enable Alexa Unlock directive (#97127)

Co-authored-by: Jan Bouwhuis <jbouwh@users.noreply.github.com>
This commit is contained in:
Marco Ranieri 2023-08-14 17:47:50 +02:00 committed by GitHub
parent 77b421887b
commit 54223fe06c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -474,7 +474,24 @@ async def async_api_unlock(
context: ha.Context,
) -> AlexaResponse:
"""Process an unlock request."""
if config.locale not in {"de-DE", "en-US", "ja-JP"}:
if config.locale not in {
"ar-SA",
"de-DE",
"en-AU",
"en-CA",
"en-GB",
"en-IN",
"en-US",
"es-ES",
"es-MX",
"es-US",
"fr-CA",
"fr-FR",
"hi-IN",
"it-IT",
"ja-JP",
"pt-BR",
}:
msg = (
"The unlock directive is not supported for the following locales:"
f" {config.locale}"