cozy / cozy-client-js

Javascript library to write Cozy applications
https://docs.cozy.io/en/cozy-client-js/README/
MIT License
11 stars 12 forks source link

feat: option to allow bypassing credentials cache #192

Closed y-lohse closed 7 years ago

y-lohse commented 7 years ago

We have a case where the scope that is being requested might be different from the one that is cached, but the oauth flow always use the cached version, so the new scope is never picked up.

I've added a flag to the client.authorize() method that explicitly tells the oauth flow to ignore the cache. It defaults to false so existing calls shouldn't be affected. Does that make sense? Is there a better way to accomplish this?

y-lohse commented 7 years ago

For cross-reference, this PR is needed by this other PR on drive.