   end
 
   defp request(env, opts) do
-    %URI{host: host, scheme: scheme, port: port, path: path} = URI.parse(env.url)
-    path = Tesla.build_url(path, env.query)
+    # Break the URI
+    %URI{host: host, scheme: scheme, port: port, path: path, query: query} = URI.parse(env.url)
+    query = (query || "") |> URI.decode_query() |> Map.to_list()
+    path = Tesla.build_url(path, env.query ++ query)
     method = case env.method do
       :head -> "GET"
       m -> m |> Atom.to_string() |> String.upcase()

  @behaviour Tesla.Adapter
  import Tesla.Adapter.Shared, only: [stream_to_fun: 1, next_chunk: 1]
  alias Mint.HTTP


  @doc false
  def call(env, opts) do

    with {:ok, conn} <- HTTP.connect(String.to_atom(scheme), host, port),
         {:ok, conn, req_ref} <- HTTP.request(conn, method, path || "/", headers, :stream),
         {:ok, conn} <- stream_request(conn, req_ref, body),
         {:ok, _conn, res = %{status: status, headers: headers}} <- stream_response(conn) do
      {:ok, status, headers, Map.get(res, :data)}
    end
  end

  defp request(method, scheme, host, port, path, headers, body, opts) do
    with {:ok, conn} <- HTTP.connect(String.to_atom(scheme), host, port),
         {:ok, conn, _req_ref} <- HTTP.request(conn, method, path || "/", headers, body || ""),
         {:ok, _conn, res = %{status: status, headers: headers}} <- stream_response(conn) do
      {:ok, status, headers, Map.get(res, :data)}
    end
  end

