Skip to content

Commit

Permalink
Compact status_ids in StatusRelationshipsPresenter (mastodon#5073)
Browse files Browse the repository at this point in the history
  • Loading branch information
zunda authored and Gargron committed Sep 24, 2017
1 parent e756c4f commit ab625c5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/presenters/status_relationships_presenter.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ def initialize(statuses, current_account_id = nil, options = {})
@pins_map = {}
else
statuses = statuses.compact
status_ids = statuses.flat_map { |s| [s.id, s.reblog_of_id] }.uniq
status_ids = statuses.flat_map { |s| [s.id, s.reblog_of_id] }.uniq.compact
conversation_ids = statuses.map(&:conversation_id).compact.uniq
pinnable_status_ids = statuses.map(&:proper).select { |s| s.account_id == current_account_id && %w(public unlisted).include?(s.visibility) }.map(&:id)

Expand Down

0 comments on commit ab625c5

Please sign in to comment.