projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[#483] Refactored blocks and follows import, added tests.
[akkoma]
/
lib
/
pleroma
/
notification.ex
diff --git
a/lib/pleroma/notification.ex
b/lib/pleroma/notification.ex
index 47f6b6ee73a5d9c5b9e5c9e43868e01d3c65f190..b5aadfd17eee840293be7fffeb0f326b01ec5bd8 100644
(file)
--- a/
lib/pleroma/notification.ex
+++ b/
lib/pleroma/notification.ex
@@
-1,3
+1,7
@@
+# Pleroma: A lightweight social networking server
+# Copyright © 2017-2018 Pleroma Authors <https://pleroma.social/>
+# SPDX-License-Identifier: AGPL-3.0-only
+
defmodule Pleroma.Notification do
use Ecto.Schema
alias Pleroma.{User, Activity, Notification, Repo, Object}
defmodule Pleroma.Notification do
use Ecto.Schema
alias Pleroma.{User, Activity, Notification, Repo, Object}
@@
-76,9
+80,8
@@
defmodule Pleroma.Notification do
end
def clear(user) do
end
def clear(user) do
- query = from(n in Notification, where: n.user_id == ^user.id)
-
- Repo.delete_all(query)
+ from(n in Notification, where: n.user_id == ^user.id)
+ |> Repo.delete_all()
end
def dismiss(%{id: user_id} = _user, id) do
end
def dismiss(%{id: user_id} = _user, id) do