summaryrefslogtreecommitdiff
path: root/priv/repo/migrations/20191104143558_fix_null_muted_notification_fields.exs
blob: e17e75983d8253742eb187293331e1a8b0f4a091 (plain)
1
2
3
4
5
6
7
defmodule Pleroma.Repo.Migrations.FixNullMutedNotificationFields do
  use Ecto.Migration

  def change do
    execute("update users set info = safe_jsonb_set(info, '{muted_notifications}', '[]'::jsonb, true) where local = true and info->'muted_notifications' = 'null'::jsonb")
  end
end