@oxyhq/core 3.4.6 → 3.4.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -112,6 +112,12 @@ export class OxyServicesBase {
112
112
  const unsubscribe = this.onTokensChanged(syncToken);
113
113
  client.setAuthRefreshHandler(async (reason) => {
114
114
  const refreshed = await this.httpService.refreshAccessToken(reason);
115
+ if (!refreshed) {
116
+ if (reason === 'response-401') {
117
+ this.clearTokens();
118
+ }
119
+ return null;
120
+ }
115
121
  syncToken(refreshed);
116
122
  return refreshed;
117
123
  });