We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 22c7112 commit 3800be6Copy full SHA for 3800be6
lib/ecto/adapters/sql/sandbox.ex
@@ -597,10 +597,11 @@ defmodule Ecto.Adapters.SQL.Sandbox do
597
"""
598
@spec allow(Ecto.Repo.t() | pid(), pid(), term()) ::
599
:ok | {:already, :owner | :allowed} | :not_found
600
- def allow(repo, parent, allow, _opts \\ []) when is_atom(repo) or is_pid(repo) do
+ def allow(repo, parent, allow, opts \\ []) when is_atom(repo) or is_pid(repo) do
601
case GenServer.whereis(allow) do
602
pid when is_pid(pid) ->
603
- %{pid: pool, opts: opts} = lookup_meta!(repo)
+ %{pid: pool, opts: meta_opts} = lookup_meta!(repo)
604
+ opts = Keyword.merge(meta_opts, opts)
605
DBConnection.Ownership.ownership_allow(pool, parent, pid, opts)
606
607
other ->
0 commit comments