projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix Reblog API
[akkoma]
/
lib
/
pleroma
/
workers
/
mute_expire_worker.ex
diff --git
a/lib/pleroma/workers/mute_expire_worker.ex
b/lib/pleroma/workers/mute_expire_worker.ex
index c8b44894e91f9a110e66329a10a9da98feb75e1a..8da903e761055f72182d07ae09d2b3b4f198283b 100644
(file)
--- a/
lib/pleroma/workers/mute_expire_worker.ex
+++ b/
lib/pleroma/workers/mute_expire_worker.ex
@@
-1,5
+1,5
@@
# Pleroma: A lightweight social networking server
# Pleroma: A lightweight social networking server
-# Copyright © 2017-202
0
Pleroma Authors <https://pleroma.social/>
+# Copyright © 2017-202
1
Pleroma Authors <https://pleroma.social/>
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Workers.MuteExpireWorker do
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Workers.MuteExpireWorker do
@@
-7,18
+7,14
@@
defmodule Pleroma.Workers.MuteExpireWorker do
@impl Oban.Worker
def perform(%Job{args: %{"op" => "unmute_user", "muter_id" => muter_id, "mutee_id" => mutee_id}}) do
@impl Oban.Worker
def perform(%Job{args: %{"op" => "unmute_user", "muter_id" => muter_id, "mutee_id" => mutee_id}}) do
- muter = Pleroma.User.get_by_id(muter_id)
- mutee = Pleroma.User.get_by_id(mutee_id)
- Pleroma.User.unmute(muter, mutee)
+ Pleroma.User.unmute(muter_id, mutee_id)
:ok
end
def perform(%Job{
args: %{"op" => "unmute_conversation", "user_id" => user_id, "activity_id" => activity_id}
}) do
:ok
end
def perform(%Job{
args: %{"op" => "unmute_conversation", "user_id" => user_id, "activity_id" => activity_id}
}) do
- user = Pleroma.User.get_by_id(user_id)
- activity = Pleroma.Activity.get_by_id(activity_id)
- Pleroma.Web.CommonAPI.remove_mute(user, activity)
+ Pleroma.Web.CommonAPI.remove_mute(user_id, activity_id)
:ok
end
end
:ok
end
end