Fix crash in StatusEdit serializer when quote posts are involved (#35036)
This commit is contained in:
parent
e28f86cbe5
commit
e8868af079
1 changed files with 1 additions and 1 deletions
|
@ -23,6 +23,6 @@ class REST::StatusEditSerializer < ActiveModel::Serializer
|
|||
end
|
||||
|
||||
def quote
|
||||
object.quote_id == status.quote&.id ? status.quote : Quote.new(state: :pending)
|
||||
object.quote_id == object.status.quote&.id ? object.status.quote : Quote.new(state: :pending)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue