mix format

This commit is contained in:
Mirai Kumiko 2025-06-12 13:31:59 +02:00
parent f3c35e8e55
commit 385afb9308
Signed by: miraikumiko
GPG key ID: 3F178B1B5E0CB278
6 changed files with 77 additions and 46 deletions

View file

@ -21,11 +21,14 @@ defmodule Nulla.Repo.Migrations.CreateInstanceSettings do
execute(fn ->
{public_key, private_key} = Nulla.KeyGen.generate_keys()
now = NaiveDateTime.utc_now() |> NaiveDateTime.truncate(:second)
domain =
Application.get_env(:nulla, NullaWeb.Endpoint, [])
|> Keyword.get(:url, [])
|> Keyword.get(:host, "localhost")
Application.get_env(:nulla, NullaWeb.Endpoint, [])
|> Keyword.get(:url, [])
|> Keyword.get(:host, "localhost")
esc = fn str -> "'#{String.replace(str, "'", "''")}'" end
sql = """
INSERT INTO instance_settings (
name, description, domain, registration,