X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;f=priv%2Frepo%2Fmigrations%2F20170906152508_create_o_auth_token.exs;h=08471bbf8b4a6d0495ee05c2ac3105ee91c72188;hb=e2782c342f063f1028575d997d8f369b1aa76964;hp=7f8550f336e25a68f15f28d8d1296fc93cbd3d0e;hpb=2a298d70f9938d1b6d5af04d8b8863fdd3299f46;p=akkoma diff --git a/priv/repo/migrations/20170906152508_create_o_auth_token.exs b/priv/repo/migrations/20170906152508_create_o_auth_token.exs index 7f8550f33..08471bbf8 100644 --- a/priv/repo/migrations/20170906152508_create_o_auth_token.exs +++ b/priv/repo/migrations/20170906152508_create_o_auth_token.exs @@ -2,12 +2,12 @@ defmodule Pleroma.Repo.Migrations.CreateOAuthToken do use Ecto.Migration def change do - create table(:oauth_tokens) do + create_if_not_exists table(:oauth_tokens) do add :app_id, references(:apps) add :user_id, references(:users) add :token, :string add :refresh_token, :string - add :valid_until, :naive_datetime + add :valid_until, :naive_datetime_usec timestamps() end