create_service_actor is now type Application
[akkoma] / priv / repo / migrations / 20230202154409_instance_actors_to_actor_type_application.exs
1 defmodule Pleroma.Repo.Migrations.InstanceActorsToActorTypeApplication do
2 use Ecto.Migration
3
4 def up do
5 execute("""
6 update users
7 set actor_type = 'Application'
8 where local
9 and (ap_id like '%/relay' or ap_id like '%/internal/fetch')
10 """)
11 end
12
13 def down do
14 execute("""
15 update users
16 set actor_type = 'Person'
17 where local
18 and (ap_id like '%/relay' or ap_id like '%/internal/fetch')
19 """)
20 end
21 end