83dac799265a1404ea1a7886915ce11b455f7c3a
[anni] / priv / repo / migrations / 20181201105617_add_uui_ds_to_user_info.exs
1 # Pleroma: A lightweight social networking server
2 # Copyright © 2017-2022 Pleroma Authors <https://pleroma.social/>
3 # SPDX-License-Identifier: AGPL-3.0-only
4
5 defmodule Pleroma.Repo.Migrations.AddUUIDsToUserInfo do
6   use Ecto.Migration
7
8   def up do
9     execute("update users set info = jsonb_set(info, '{\"id\"}', to_jsonb(uuid_generate_v4()))")
10   end
11
12   def down, do: :ok
13 end