Merge pull request 'Manually define PATH for Arch Linux users in systemd unit' (...
[akkoma] / priv / repo / migrations / 20211125110126_force_pinned_objects_to_exist.exs
1 defmodule Pleroma.Repo.Migrations.ForcePinnedObjectsToExist do
2 use Ecto.Migration
3
4 def change do
5 execute("UPDATE users SET pinned_objects = '{}' WHERE pinned_objects IS NULL")
6
7 alter table("users") do
8 modify(:pinned_objects, :map, null: false, default: %{})
9 end
10 end
11 end