mirror of
https://github.com/bonfire-networks/bonfire-app.git
synced 2024-04-28 23:38:44 +00:00
23 lines
622 B
Elixir
23 lines
622 B
Elixir
defmodule Bonfire.Social.Repo.Migrations.ProfileImages do
|
|
use Ecto.Migration
|
|
|
|
import Pointers.Migration
|
|
|
|
def up do
|
|
drop_if_exists(
|
|
constraint("bonfire_data_social_profile", "bonfire_data_social_profile_icon_id_fkey")
|
|
)
|
|
|
|
drop_if_exists(
|
|
constraint("bonfire_data_social_profile", "bonfire_data_social_profile_image_id_fkey")
|
|
)
|
|
|
|
alter table("bonfire_data_social_profile") do
|
|
Ecto.Migration.add_if_not_exists(:icon_id, strong_pointer(Bonfire.Files.Media))
|
|
Ecto.Migration.add_if_not_exists(:image_id, strong_pointer(Bonfire.Files.Media))
|
|
end
|
|
end
|
|
|
|
def down, do: nil
|
|
end
|