diff options
author | lain <lain@soykaf.club> | 2020-05-01 15:58:47 +0200 |
---|---|---|
committer | lain <lain@soykaf.club> | 2020-05-01 15:58:47 +0200 |
commit | 3453e54e6b00ca2aced07746ad4cfc22ebc404fb (patch) | |
tree | 867259fd4f09321dae4bd9fdee13d841501b5af2 | |
parent | a912f72a3674f80fe665db466295192b4dab82a9 (diff) | |
download | pleroma-3453e54e6b00ca2aced07746ad4cfc22ebc404fb.tar.gz |
MappedSignatureToIdentityPlug: Fix.
-rw-r--r-- | lib/pleroma/plugs/mapped_signature_to_identity_plug.ex | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/pleroma/plugs/mapped_signature_to_identity_plug.ex b/lib/pleroma/plugs/mapped_signature_to_identity_plug.ex index 84b7c5d83..f44d4dee5 100644 --- a/lib/pleroma/plugs/mapped_signature_to_identity_plug.ex +++ b/lib/pleroma/plugs/mapped_signature_to_identity_plug.ex @@ -13,8 +13,9 @@ defmodule Pleroma.Web.Plugs.MappedSignatureToIdentityPlug do def init(options), do: options defp key_id_from_conn(conn) do - with %{"keyId" => key_id} <- HTTPSignatures.signature_for_conn(conn) do - Signature.key_id_to_actor_id(key_id) + with %{"keyId" => key_id} <- HTTPSignatures.signature_for_conn(conn), + {:ok, ap_id} <- Signature.key_id_to_actor_id(key_id) do + ap_id else _ -> nil |