Introduce support for custom nginx error pages

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2020-10-09 12:17:33 +02:00
parent 3a3a500e42
commit 07a5d10421
31 changed files with 476 additions and 63 deletions

View File

@@ -39,7 +39,11 @@ defmodule Mobilizon.Web.ErrorView do
end
def render("500.html", _assigns) do
"Internal server error"
Mobilizon.Config.instance_config()
|> Keyword.get(:default_language, "en")
|> Gettext.put_locale()
render("500_page.html", %{})
end
# In case no render clause matches or no