Skip to content

Commit d45a6a0

Browse files
committed
refresh token spelling bug
1 parent b29e10c commit d45a6a0

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

frontend/src/APIClients/BaseAPIClient.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ baseAPIClient.interceptors.request.use(async (config: AxiosRequestConfig) => {
3535
// Check if the access_token is expired, if it is then request a refresh
3636
if (
3737
decodedToken &&
38+
// If it a string (and not an object) then something went wrong
3839
(typeof decodedToken === "string" ||
3940
// Checks the time of expiration in seconds (division by 1000 because its in ms)
4041
decodedToken.exp <= Math.round(new Date().getTime() / 1000))

0 commit comments

Comments
 (0)