diff options
author | rinpatch <rinpatch@sdf.org> | 2020-09-05 21:17:03 +0300 |
---|---|---|
committer | rinpatch <rinpatch@sdf.org> | 2020-09-05 21:17:03 +0300 |
commit | 5298de3be6683022fa53cc011dd567e8b2a706b9 (patch) | |
tree | bbe1f4ee77a4f6dbdfb540f02f814867e57b73a1 | |
parent | 8c8fb84a38de31e7ef95661ea162bf2aded8967b (diff) | |
download | pleroma-5298de3be6683022fa53cc011dd567e8b2a706b9.tar.gz |
ConnectionPool middleware: fix a crash due to unimplemented behaviour
Structs don't implement Access behaviour, so this crashed. Tests didn't
catch it and I didn't test that part of the codepath. Very sorry
-rw-r--r-- | lib/pleroma/tesla/middleware/connection_pool.ex | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/pleroma/tesla/middleware/connection_pool.ex b/lib/pleroma/tesla/middleware/connection_pool.ex index 5909e98d6..049db6eb3 100644 --- a/lib/pleroma/tesla/middleware/connection_pool.ex +++ b/lib/pleroma/tesla/middleware/connection_pool.ex @@ -32,7 +32,7 @@ defmodule Pleroma.Tesla.Middleware.ConnectionPool do {:ok, env} -> unless opts[:adapter][:body_as] == :chunks do ConnectionPool.release_conn(conn_pid) - {:ok, pop_in(env[:opts][:adapter][:conn])} + {:ok, pop_in(env.opts[:adapter][:conn])} else {:ok, env} end |