Skip to content

Commit

Permalink
chore: Remove unnecessary check
Browse files Browse the repository at this point in the history
  • Loading branch information
SteveGT96 committed Nov 19, 2024
1 parent ffdc8ab commit 3df5426
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/libraries/apiUtils/wrapper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,7 @@ export function wrapper<T>(callback: () => Observable<T>): Observable<T> {
catchError((error) => {
if (error.status === 401) {
const refreshToken = SessionStorage.read(AUTH_KEY)?.refreshToken;
if (
error.status === 401 &&
refreshToken &&
!refreshTokenHasExpired(refreshToken)
) {
if (refreshToken && !refreshTokenHasExpired(refreshToken)) {
return from(
mutex.runExclusive(async () => {
const token = SessionStorage.read(AUTH_KEY)?.token;
Expand Down

0 comments on commit 3df5426

Please sign in to comment.