Skip to content
New issue

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

Doesn't always properly parse expires_at #58

Closed
jeffutter opened this issue Jul 28, 2016 · 0 comments
Closed

Doesn't always properly parse expires_at #58

jeffutter opened this issue Jul 28, 2016 · 0 comments

Comments

@jeffutter
Copy link
Contributor

I'm dealing with an API that returns the authorize request as such:

{ "access_token": "k8sbPR4is2C7ipTYgEbi8fe470mp", "refresh_token": "dQJiREMfaHhDBoGohIj7JEpIOYYk9Jif", "expires_in": "599" }

With expires_in as a string. With the existing code, here: https://github.com/scrogson/oauth2/blob/master/lib/oauth2/access_token.ex#L137 it would parse that into the integer 599, which is still not the correct value for expires_at. In this case, it would have to call expires_at again with the integer value to get the timestamp.

I'm not sure if having it call expires_at(int) at the end of the string version would break anything else or not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant