Fix dialyzer error in status controller: Add catch-all pattern for translate function
This commit is contained in:
parent
daad35aeb9
commit
47ebbc4d21
1 changed files with 3 additions and 0 deletions
|
|
@ -584,6 +584,9 @@ defmodule Pleroma.Web.MastodonAPI.StatusController do
|
|||
|
||||
{:error, error} when error in [:unexpected_response, :quota_exceeded, :too_many_requests] ->
|
||||
render_error(conn, :service_unavailable, "Translation service not available")
|
||||
|
||||
_ ->
|
||||
render_error(conn, :internal_server_error, "Translation failed")
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue