fix for new instances

This commit is contained in:
Alexander Strizhakov 2019-06-16 10:01:15 +00:00 committed by lain
parent 135c196769
commit 7a4228be5a

View File

@ -9,7 +9,8 @@ defmodule Pleroma.Config.TransferTask do
end end
def load_and_update_env do def load_and_update_env do
if Pleroma.Config.get([:instance, :dynamic_configuration]) do if Pleroma.Config.get([:instance, :dynamic_configuration]) and
Ecto.Adapters.SQL.table_exists?(Pleroma.Repo, "config") do
Pleroma.Repo.all(Config) Pleroma.Repo.all(Config)
|> Enum.each(&update_env(&1)) |> Enum.each(&update_env(&1))
end end