gardner / react-oauth2-pkce

React auth provider that works with AWS cognito PKCE🛡️🔒
49 stars 57 forks source link

fix: convert "expires_in" to integer #35

Open andrii-maglovanyi opened 2 years ago

andrii-maglovanyi commented 2 years ago

expires_in can be given as a string, causing string to number concatenation and incorrect expires_at calculation. Fixed it by to converting it into a number, if it isn't already.