Line up scopes in order of the flow

This commit is contained in:
David Heinemeier Hansson
2025-04-15 16:13:54 +02:00
parent 8e479dddba
commit f30a9308d2
+2 -3
View File
@@ -6,10 +6,9 @@ module Card::Engageable
included do
has_one :engagement, dependent: :destroy, class_name: "Card::Engagement"
scope :doing, -> { published.active.joins(:engagement) }
scope :considering, -> { published_or_drafted_by(Current.user).active.where.missing(:engagement) }
scope :stagnated, -> { doing.where(last_active_at: ..STAGNATED_AFTER.ago) }
scope :doing, -> { published.active.joins(:engagement) }
scope :stagnated, -> { doing.where(last_active_at: ..STAGNATED_AFTER.ago) }
end
class_methods do