amazon-archives / amazon-cognito-auth-js

The Amazon Cognito Auth SDK for JavaScript simplifies adding sign-up, sign-in with user profile functionality to web apps.
Apache License 2.0
424 stars 232 forks source link

fix: Call onFailure for code flow too #177

Closed manueliglesias closed 5 years ago

manueliglesias commented 5 years ago

Issue #, if available: Fixes #176

Description of changes: parseCognitoWebResponse doesn't call onFailure for code, only for token. This PR adds error checking for code flow.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

manueliglesias commented 5 years ago

Duplicate of #135