Fix relation.ex
This commit is contained in:
parent
198f8e7e83
commit
31f6c9f9ad
1 changed files with 16 additions and 1 deletions
|
@ -45,7 +45,22 @@ defmodule Nulla.Relations.Relation do
|
|||
:remote_actor_id
|
||||
])
|
||||
|> maybe_put_id()
|
||||
|> validate_required([:local_actor_id, :remote_actor_id])
|
||||
|> validate_required([
|
||||
:following,
|
||||
:followed_by,
|
||||
:showing_replies,
|
||||
:showings_reblogs,
|
||||
:notifying,
|
||||
:muting,
|
||||
:muting_notifications,
|
||||
:blocking,
|
||||
:blocked_by,
|
||||
:domain_blocking,
|
||||
:requested,
|
||||
:note,
|
||||
:local_actor_id,
|
||||
:remote_actor_id
|
||||
])
|
||||
|> unique_constraint([:local_actor_id, :remote_actor_id])
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue