mirror of
https://git.pleroma.social/pleroma/pleroma.git
synced 2024-12-23 16:40:29 +00:00
Merge branch 'pleroma-result-1_13' into 'develop'
move result into with guard See merge request pleroma/pleroma!3557
This commit is contained in:
parent
991b26f494
commit
bf0b32c9aa
1 changed files with 11 additions and 12 deletions
|
@ -63,18 +63,17 @@ defmodule Pleroma.Web.ActivityPub.Publisher do
|
||||||
date: date
|
date: date
|
||||||
})
|
})
|
||||||
|
|
||||||
with {:ok, %{status: code}} when code in 200..299 <-
|
with {:ok, %{status: code}} = result when code in 200..299 <-
|
||||||
result =
|
HTTP.post(
|
||||||
HTTP.post(
|
inbox,
|
||||||
inbox,
|
json,
|
||||||
json,
|
[
|
||||||
[
|
{"Content-Type", "application/activity+json"},
|
||||||
{"Content-Type", "application/activity+json"},
|
{"Date", date},
|
||||||
{"Date", date},
|
{"signature", signature},
|
||||||
{"signature", signature},
|
{"digest", digest}
|
||||||
{"digest", digest}
|
]
|
||||||
]
|
) do
|
||||||
) do
|
|
||||||
if not Map.has_key?(params, :unreachable_since) || params[:unreachable_since] do
|
if not Map.has_key?(params, :unreachable_since) || params[:unreachable_since] do
|
||||||
Instances.set_reachable(inbox)
|
Instances.set_reachable(inbox)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue