We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why it's not easy to use omniauth-oauth2 with https://github.com/intridea/oauth2?
omniauth-oauth2
From omniauth i get credentials hash like this:
credentials do hash = {'token' => access_token.token} hash.merge!('refresh_token' => access_token.refresh_token) if access_token.expires? && access_token.refresh_token hash.merge!('expires_at' => access_token.expires_at) if access_token.expires? hash.merge!('expires' => access_token.expires?) hash end
https://github.com/intridea/omniauth-oauth2/blob/master/lib/omniauth/strategies/oauth2.rb#L41
And it's impossible to use OAuth2::AccessToken.from_hash() method without modify the credentials hash https://github.com/intridea/oauth2/blob/master/lib/oauth2/access_token.rb#L45
OAuth2::AccessToken.from_hash()
The text was updated successfully, but these errors were encountered:
Do you have a patch for this? I would be happy to accept a pull request to make this easier to use.
Sorry, something went wrong.
I'm pretty sure this is fixed in newer oauth2 libraries. It checks for both Symbol and String keys which I assume was the issue here.
No branches or pull requests
Why it's not easy to use
omniauth-oauth2
with https://github.com/intridea/oauth2?From omniauth i get credentials hash like this:
https://github.com/intridea/omniauth-oauth2/blob/master/lib/omniauth/strategies/oauth2.rb#L41
And it's impossible to use
OAuth2::AccessToken.from_hash()
method without modify the credentials hash https://github.com/intridea/oauth2/blob/master/lib/oauth2/access_token.rb#L45The text was updated successfully, but these errors were encountered: