Skip to content

Commit

Permalink
Update client.ex
Browse files Browse the repository at this point in the history
Fix attribute variable name to be more explicit that we expect the `Client` schema type.
  • Loading branch information
zorn authored Jul 12, 2023
1 parent 7589795 commit 8db3985
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/oauth2/client.ex
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ defmodule OAuth2.Client do
"""
@spec refresh_token(t, params, headers, Keyword.t()) ::
{:ok, Client.t()} | {:error, Response.t()} | {:error, Error.t()}
def refresh_token(token, params \\ [], headers \\ [], opts \\ [])
def refresh_token(client, params \\ [], headers \\ [], opts \\ [])

def refresh_token(%Client{token: %{refresh_token: nil}}, _params, _headers, _opts) do
{:error, %Error{reason: "Refresh token not available."}}
Expand Down

0 comments on commit 8db3985

Please sign in to comment.