2
0

Fix crash in StatusEdit serializer when quote posts are involved (#35036)

This commit is contained in:
Claire
2025-06-13 16:59:52 +02:00
committed by GitHub
parent e28f86cbe5
commit e8868af079

View File

@@ -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