fix: add a final fallback if we have default_language: nil in instance config

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel 2023-11-21 18:10:54 +01:00
parent 262d1fcd4d
commit cd53062c01
No known key found for this signature in database
GPG Key ID: A061B9DDE0CA0773
1 changed files with 2 additions and 0 deletions

View File

@ -53,6 +53,8 @@ defmodule Mobilizon.Web.ErrorView do
locale =
Mobilizon.Config.instance_config()
|> Keyword.get(:default_language, "en")
# Just in case
|> Kernel.||("en")
Gettext.put_locale(locale)