1 defmodule Pleroma.Repo.Migrations.CreateNotifications do
5 create_if_not_exists table(:notifications) do
6 add(:user_id, references(:users, on_delete: :delete_all))
7 add(:activity_id, references(:activities, on_delete: :delete_all))
8 add(:seen, :boolean, default: false)
13 create_if_not_exists(index(:notifications, [:user_id]))