This commit is contained in:
2020-06-25 04:09:27 +03:00
parent d7822675a3
commit 305e8f29c9
3 changed files with 6 additions and 7 deletions

View File

@@ -85,10 +85,9 @@ defmodule MicrosoftTranslator.Client do
end
defp transform_response(response, :translate) do
result =
response
|> List.first()
|> Map.take([:translations])
response
|> List.first()
|> Map.take([:translations])
end
defp transform_response(response, :languages) do
@@ -125,7 +124,7 @@ defmodule MicrosoftTranslator.Client do
{:error, reason}
:unknown ->
exit({:unexpected, message})
{:unexpected, message}
end
end
end