mirror of
https://git.pleroma.social/pleroma/pleroma.git
synced 2024-12-24 09:00:29 +00:00
fix http request in Salmon
This commit is contained in:
parent
ec34de0c1f
commit
97252a27d9
1 changed files with 6 additions and 4 deletions
|
@ -158,14 +158,16 @@ defmodule Pleroma.Web.Salmon do
|
||||||
end
|
end
|
||||||
|
|
||||||
defp send_to_user(%{info: %{salmon: salmon}}, feed, poster) do
|
defp send_to_user(%{info: %{salmon: salmon}}, feed, poster) do
|
||||||
with {:ok, %{status_code: code}} <-
|
with {:ok, %{status: code}} <-
|
||||||
poster.(
|
poster.(
|
||||||
salmon,
|
salmon,
|
||||||
feed,
|
feed,
|
||||||
[{"Content-Type", "application/magic-envelope+xml"}],
|
[{"Content-Type", "application/magic-envelope+xml"}],
|
||||||
|
adapter: [
|
||||||
timeout: 10000,
|
timeout: 10000,
|
||||||
recv_timeout: 20000,
|
recv_timeout: 20000,
|
||||||
hackney: [pool: :default]
|
pool: :default
|
||||||
|
]
|
||||||
) do
|
) do
|
||||||
Logger.debug(fn -> "Pushed to #{salmon}, code #{code}" end)
|
Logger.debug(fn -> "Pushed to #{salmon}, code #{code}" end)
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue