Update google_translate to use async_add_executor_job (#41925)

This commit is contained in:
J. Nick Koston authored and GitHub committed 2020-10-16 13:15:01 +02:00
1 parent c9ba5bfebd
commit 83af805522
1 file changed
+3 -1
@@ -123,7 +123,9 @@ class GoogleProvider(Provider):
data = b""
for idx, part in enumerate(message_parts):
part_token = await self.hass.async_add_job(token.calculate_token, part)
part_token = await self.hass.async_add_executor_job(
token.calculate_token, part
)
url_param = {
"ie": "UTF-8",