   # file, we decided to go with a more explicit approach of
   # asking them to change it to avoid later surprises and
   # headaches.
-  defp with_matching_only(%{opts: other_opts} = other, %{opts: opts} = dep, true) do
+  defp with_matching_only(other, other_opts, dep, opts, true) do
     case Keyword.fetch(other_opts, :only) do
       {:ok, other_only} ->
         case Keyword.fetch(opts, :only) do

    if match, do: acc
  end

  # When in_upper is true
  #
  # When a parent dependency specifies :only that is a subset

  # only solution is to merge the environments. We have decided to
  # perform it explicitly as, opposite to in_upper above, the
  # dependencies are never really laid out in the parent tree.
  defp with_matching_only(other, other_opts, dep, opts, false) do
    other_only = Keyword.get(other_opts, :only)
    only = Keyword.get(opts, :only)
    if other_only && only do
