pocket-casts-ios
pocket-casts-ios copied to clipboard
Apple SSO: Consolidate Token Refresh paths
| 📘 Project: #381 | Depends on #409 |
|---|
| 📓 For Apple SSO testing: In my testing, Apple SSO didn't always return the email in the simulator, so testing with a physical device is recommended. |
|---|
Consolidates the refresh password token flow to use the existing API methods.
The token refresh methods have a 30.seconds timeout which seems very long, especially when the default is already 15.seconds, so I didn't maintain the 30.seconds period when porting to the existing methods.
I did, however, modify the login paths (SSO and Username/Password) to use the .reloadIgnoringLocalCacheData policy, as that just seems wise for auth calls.
To test
This can be tested with the same process as https://github.com/Automattic/pocket-casts-ios/pull/392 but using Username and Password log in instead of SSO
Checklist
- [x] I have considered if this change warrants user-facing release notes and have added them to
CHANGELOG.mdif necessary. - [x] I have considered adding unit tests for my changes.
- [ ] I have updated (or requested that someone edit) the spreadsheet to reflect any new or changed analytics.
@chipsnyder it looks like there are build errors on this PR. 🤔
😅 Got moving too fast yesterday and didn't push the last change to this branch.
There are some changes coming to the login/token endpoints that will require more changes how we handle the token refresh/etc. So I am going to close this for now and revisit these improvements later.