mirror of
https://github.com/mastodon/mastodon.git
synced 2026-04-25 07:56:08 -05:00
Auto accept account added to collection (#37805)
This commit is contained in:
parent
75ba314e6b
commit
ae30c40335
|
|
@ -27,7 +27,7 @@ class CreateCollectionService
|
|||
@accounts_to_add.each do |account_to_add|
|
||||
raise Mastodon::NotPermittedError, I18n.t('accounts.errors.cannot_be_added_to_collections') unless AccountPolicy.new(@account, account_to_add).feature?
|
||||
|
||||
@collection.collection_items.build(account: account_to_add)
|
||||
@collection.collection_items.build(account: account_to_add, state: :accepted)
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user