Change default timezone to Etc/UTC

This commit is contained in:
Uku Taht 2021-04-15 11:03:06 +03:00
parent 80abfa6ef6
commit 956e92f161
2 changed files with 3 additions and 3 deletions

View File

@ -7,7 +7,7 @@ defmodule Plausible.Site do
@derive {Jason.Encoder, only: [:domain, :timezone]}
schema "sites" do
field :domain, :string
field :timezone, :string, default: "Etc/Greenwich"
field :timezone, :string, default: "Etc/UTC"
field :public, :boolean
many_to_many :members, User, join_through: Plausible.Site.Membership

View File

@ -23,7 +23,7 @@ defmodule PlausibleWeb.Api.ExternalSitesControllerTest do
}
end
test "timezone defaults to Etc/Greenwich", %{conn: conn} do
test "timezone defaults to Etc/UTC", %{conn: conn} do
conn =
post(conn, "/api/v1/sites", %{
"domain" => "some-site.domain"
@ -31,7 +31,7 @@ defmodule PlausibleWeb.Api.ExternalSitesControllerTest do
assert json_response(conn, 200) == %{
"domain" => "some-site.domain",
"timezone" => "Etc/Greenwich"
"timezone" => "Etc/UTC"
}
end