Fetch unread notification count only for supported notification types (#14923)

* Fetch unread notification count only for supported notification types
This commit is contained in:
Alexander 2023-02-01 15:36:33 +01:00 committed by GitHub
parent b8eab0c328
commit 9ded9da7e3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 1 deletions

View File

@ -366,7 +366,7 @@
{:events [:activity-center.notifications/fetch-unread-count]} {:events [:activity-center.notifications/fetch-unread-count]}
[_] [_]
{:json-rpc/call [{:method "wakuext_unreadAndAcceptedActivityCenterNotificationsCount" {:json-rpc/call [{:method "wakuext_unreadAndAcceptedActivityCenterNotificationsCount"
:params [] :params [types/all-supported]
:on-success #(rf/dispatch [:activity-center.notifications/fetch-unread-count-success :on-success #(rf/dispatch [:activity-center.notifications/fetch-unread-count-success
%]) %])
:on-error #()}]}) :on-error #()}]})

View File

@ -9,6 +9,15 @@
(def ^:const admin 8) (def ^:const admin 8)
(def ^:const contact-verification 10) (def ^:const contact-verification 10)
(def ^:const all-supported
#{one-to-one-chat
private-group-chat
mention
reply
contact-request
admin
contact-verification})
;; TODO: Replace with correct enum values once status-go implements them. ;; TODO: Replace with correct enum values once status-go implements them.
(def ^:const tx 66612) (def ^:const tx 66612)
(def ^:const system 66614) (def ^:const system 66614)