Skip to content

Commit

Permalink
Stop using decode_pair/2 in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
whatyouhide committed Dec 24, 2023
1 parent 7545f5e commit c22e12b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/plug/conn/query_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,9 @@ defmodule Plug.Conn.QueryTest do
end

defp decode_pair(pairs) do
Enum.reduce(Enum.reverse(pairs), %{}, &Plug.Conn.Query.decode_pair(&1, &2))
pairs
|> Enum.reduce(Plug.Conn.Query.decode_init(), &Plug.Conn.Query.decode_each/2)
|> Plug.Conn.Query.decode_done()
end
end
end

0 comments on commit c22e12b

Please sign in to comment.