parent
6dd40ad7cd
commit
d18b233239
7 changed files with 13 additions and 13 deletions
|
@ -56,7 +56,7 @@ class DeliveryAntennaService
|
|||
antennas = antennas.where(ignore_reblog: false) if @status.reblog?
|
||||
antennas = antennas.where(stl: false, ltl: false)
|
||||
|
||||
collection = AntennaCollection.new(@status, @update, false)
|
||||
collection = AntennaCollection.new(@status, @update)
|
||||
content = extract_status_plain_text_with_spoiler_text(@status)
|
||||
|
||||
antennas.in_batches do |ans|
|
||||
|
@ -89,7 +89,7 @@ class DeliveryAntennaService
|
|||
antennas = antennas.where(account: @account.followers).or(antennas.where(account: @account)).where('insert_feeds IS FALSE OR list_id > 0') if home_post && !@status.limited_visibility?
|
||||
antennas = antennas.where(account: @status.mentioned_accounts).or(antennas.where(account: @account)).where('insert_feeds IS FALSE OR list_id > 0') if @status.limited_visibility?
|
||||
|
||||
collection = AntennaCollection.new(@status, @update, home_post)
|
||||
collection = AntennaCollection.new(@status, @update, stl_home: home_post)
|
||||
|
||||
antennas.in_batches do |ans|
|
||||
ans.each do |antenna|
|
||||
|
@ -111,7 +111,7 @@ class DeliveryAntennaService
|
|||
antennas = Antenna.available_ltls
|
||||
antennas = antennas.where(account_id: Account.without_suspended.joins(:user).select('accounts.id').where('users.current_sign_in_at > ?', User::ACTIVE_DURATION.ago))
|
||||
|
||||
collection = AntennaCollection.new(@status, @update, false)
|
||||
collection = AntennaCollection.new(@status, @update)
|
||||
|
||||
antennas.in_batches do |ans|
|
||||
ans.each do |antenna|
|
||||
|
@ -140,7 +140,7 @@ class DeliveryAntennaService
|
|||
end
|
||||
|
||||
class AntennaCollection
|
||||
def initialize(status, update, stl_home = false) # rubocop:disable Style/OptionalBooleanParameter
|
||||
def initialize(status, update, stl_home: false)
|
||||
@status = status
|
||||
@update = update
|
||||
@stl_home = stl_home
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue