mirror of
https://github.com/mastodon/mastodon.git
synced 2024-11-25 15:09:29 +00:00
Fix scope latest of ReportNote (#9630)
This commit is contained in:
parent
0c1e4bb969
commit
a8ba291beb
|
@ -15,7 +15,7 @@ class ReportNote < ApplicationRecord
|
||||||
belongs_to :account
|
belongs_to :account
|
||||||
belongs_to :report, inverse_of: :notes, touch: true
|
belongs_to :report, inverse_of: :notes, touch: true
|
||||||
|
|
||||||
scope :latest, -> { reorder('created_at ASC') }
|
scope :latest, -> { reorder(created_at: :desc) }
|
||||||
|
|
||||||
validates :content, presence: true, length: { maximum: 500 }
|
validates :content, presence: true, length: { maximum: 500 }
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue