redux-token-auth icon indicating copy to clipboard operation
redux-token-auth copied to clipboard

Backend sends empty access-token

Open p-engelkes opened this issue 7 years ago • 1 comments

I have a problem that after a user is logged in and I refresh the page several times that sometimes the Response returns a status code 200 but the access-token is empty. This empty access-token gets saved in the localStorage and after I refresh the page again no verification is executed.

Would it be the correct solution not to update the access-token if an empty token is returned in the Response? If so I will make a PR.

p-engelkes avatar Dec 29 '17 09:12 p-engelkes

This can be fixed with setting change_headers_on_each_request = true in the devise_token_auth intiailizer.

p-engelkes avatar Jan 02 '18 12:01 p-engelkes