aboutsummaryrefslogtreecommitdiff
path: root/lib/pleroma/web/activity_pub/utils.ex
diff options
context:
space:
mode:
authorRoman Chvanikov <chvanikoff@pm.me>2019-07-16 16:19:19 +0300
committerRoman Chvanikov <chvanikoff@pm.me>2019-07-16 16:19:19 +0300
commit9bca70b10a4c1a7664616b90c50c10c2a8a1003e (patch)
treed228fe80c6ed7869e4b24fd758b03d2ab489d7d6 /lib/pleroma/web/activity_pub/utils.ex
parentb052a9d4d0323eb64c0a741a499906659a674244 (diff)
parentd3b922276138cf7aaa896d52a8e35113a40e22dc (diff)
downloadpleroma-9bca70b10a4c1a7664616b90c50c10c2a8a1003e.tar.gz
Merge develop
Diffstat (limited to 'lib/pleroma/web/activity_pub/utils.ex')
-rw-r--r--lib/pleroma/web/activity_pub/utils.ex8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/pleroma/web/activity_pub/utils.ex b/lib/pleroma/web/activity_pub/utils.ex
index 4288ea4c8..c146f59d4 100644
--- a/lib/pleroma/web/activity_pub/utils.ex
+++ b/lib/pleroma/web/activity_pub/utils.ex
@@ -25,12 +25,8 @@ defmodule Pleroma.Web.ActivityPub.Utils do
# Some implementations send the actor URI as the actor field, others send the entire actor object,
# so figure out what the actor's URI is based on what we have.
- def get_ap_id(object) do
- case object do
- %{"id" => id} -> id
- id -> id
- end
- end
+ def get_ap_id(%{"id" => id} = _), do: id
+ def get_ap_id(id), do: id
def normalize_params(params) do
Map.put(params, "actor", get_ap_id(params["actor"]))