Skip to content

Commit

Permalink
avoid refreshing auth token if not logged in
Browse files Browse the repository at this point in the history
  • Loading branch information
radeusgd committed Aug 29, 2024
1 parent 3c99334 commit b1ca35e
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,11 @@ public RequestFailureException(String message, Throwable cause) {
* environment does not change during execution.
*/
static void refreshRequestConfig() {
INSTANCE.requestConfig = INSTANCE.getRequestConfig();
// We only do the refresh if the request config was set before. It may not be set if the user is
// not logged in to the cloud, and trying to refresh it then will fail with `Not_Logged_In`
// error.
if (INSTANCE.requestConfig != null) {
INSTANCE.requestConfig = INSTANCE.getRequestConfig();
}
}
}

0 comments on commit b1ca35e

Please sign in to comment.