about summary refs log tree commit diff
path: root/app/services/notify_service.rb
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2021-09-26 13:23:28 +0200
committerGitHub <noreply@github.com>2021-09-26 13:23:28 +0200
commita0d4129893c797f78d28ba9df5d35646f7bb0d80 (patch)
treebe6b5c2dbb4e648ede66e96eda2adcab2bac33ee /app/services/notify_service.rb
parent52e5c07948c4c91b73062846e1f19ea278ec0e24 (diff)
Refactor notifications to go through a separate stream in streaming API (#16765)
Eliminate need to have custom notifications filtering logic in the
streaming API code by publishing notifications into a separate stream
and then simply using the multi-stream capability to subscribe to that
stream when necessary
Diffstat (limited to 'app/services/notify_service.rb')
-rw-r--r--app/services/notify_service.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/notify_service.rb b/app/services/notify_service.rb
index fc187db40..a1b5ca1e3 100644
--- a/app/services/notify_service.rb
+++ b/app/services/notify_service.rb
@@ -127,7 +127,7 @@ class NotifyService < BaseService
   def push_notification!
     return if @notification.activity.nil?
 
-    Redis.current.publish("timeline:#{@recipient.id}", Oj.dump(event: :notification, payload: InlineRenderer.render(@notification, @recipient, :notification)))
+    Redis.current.publish("timeline:#{@recipient.id}:notifications", Oj.dump(event: :notification, payload: InlineRenderer.render(@notification, @recipient, :notification)))
     send_push_notifications!
   end