chore: Remove unnecessary fields from notification payload (#4403)
This commit is contained in:
parent
75ce5345a9
commit
c2afdd5c93
1 changed files with 8 additions and 2 deletions
|
@ -64,9 +64,15 @@ class Notification < ApplicationRecord
|
|||
|
||||
def primary_actor_data
|
||||
if %w[assigned_conversation_new_message conversation_mention].include? notification_type
|
||||
primary_actor.conversation.push_event_data
|
||||
{
|
||||
id: primary_actor.conversation.push_event_data[:id],
|
||||
meta: primary_actor.conversation.push_event_data[:meta]
|
||||
}
|
||||
else
|
||||
primary_actor.push_event_data
|
||||
{
|
||||
id: primary_actor.push_event_data[:id],
|
||||
meta: primary_actor.push_event_data[:meta]
|
||||
}
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue