FIX: removes destroyed mentioned used (#21841)

This would generate a 500 as we would call id on a nil object.
This commit is contained in:
Joffrey JAFFEUX
2023-05-31 00:21:09 +02:00
committed by GitHub
parent e3e7b080c6
commit 6c3a51328c

View File

@@ -30,6 +30,7 @@ module Chat
object
.chat_mentions
.map(&:user)
.compact
.sort_by(&:id)
.map { |user| BasicUserWithStatusSerializer.new(user, root: false) }
.as_json