Skip to content

Commit

Permalink
Update lib/tesla.ex
Browse files Browse the repository at this point in the history
Co-authored-by: Yordis Prieto <[email protected]>
  • Loading branch information
RudolfMan and yordis authored Feb 3, 2023
1 parent d5c9cac commit 7a3e513
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/tesla.ex
Original file line number Diff line number Diff line change
Expand Up @@ -529,7 +529,9 @@ defmodule Tesla do
iex> Tesla.build_url("http://api.example.com", [user_name: "John Smith"], :rfc3986)
"http://api.example.com?user_name=John%20Smith"
"""
@spec build_url(Tesla.Env.url(), Tesla.Env.query(), :rfc3986 | :www_form) :: binary
@type encoding_strategy :: :rfc3986 | :www_form

@spec build_url(Tesla.Env.url(), Tesla.Env.query(), encoding_strategy) :: binary
def build_url(url, query, encoding \\ :www_form)

def build_url(url, [], _encoding), do: url
Expand Down

0 comments on commit 7a3e513

Please sign in to comment.