Skip to content
This repository was archived by the owner on Nov 8, 2022. It is now read-only.

Commit 61fcd0e

Browse files
committed
refactor(notify): fix notify update
1 parent aa80d1a commit 61fcd0e

File tree

2 files changed

+35
-1
lines changed

2 files changed

+35
-1
lines changed

lib/groupher_server/delivery/delegates/notification.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ defmodule GroupherServer.Delivery.Delegate.Notification do
6868
|> done
6969
end)
7070
|> Multi.run(:update_user_mailbox_status, fn _, _ ->
71-
Enum.each(notifications, &Accounts.update_mailbox_status(&1.to_user_id)) |> done
71+
Enum.each(notifications, &Accounts.update_mailbox_status(&1.user_id)) |> done
7272
end)
7373
|> Repo.transaction()
7474
|> result()

test/groupher_server_web/query/accounts/mailbox_test.exs

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,40 @@ defmodule GroupherServer.Test.Query.Accounts.Mailbox do
106106
end
107107
end
108108

109+
describe "[mark_read/all]" do
110+
test "can mark read a mention" do
111+
#
112+
true
113+
end
114+
115+
test "can mark read all mentions" do
116+
#
117+
true
118+
end
119+
120+
test "can mark read a notification" do
121+
#
122+
true
123+
end
124+
125+
test "can mark read all notifications" do
126+
#
127+
true
128+
end
129+
end
130+
131+
describe "[paged messages]" do
132+
test "can get paged mentions" do
133+
#
134+
true
135+
end
136+
137+
test "can get paged notifications" do
138+
#
139+
true
140+
end
141+
end
142+
109143
# describe "[accounts mention]" do
110144
# @query """
111145
# query($filter: MessagesFilter!) {

0 commit comments

Comments
 (0)