Skip to content

Commit

Permalink
Merge pull request #410 from SquareTable/355-logging-out-displays-two…
Browse files Browse the repository at this point in the history
…-errors-if-refresh-token-has-already-expired

fix: error no longer displays when logging out with expired refresh token
  • Loading branch information
Sebastian-Webster authored Jun 22, 2024
2 parents 1b0d87d + 0496c5c commit f081aed
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion App.js
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ const App = () => {
if (status == 401) {
console.log("No JWT passed?")
//setAuthAsHeaders() // why not // cant do anymore since userid is used in the keys for multiple accounts
} else if (status == 403) {
} else if (status == 403 && error?.response?.config?.url !== `${serverUrl}/tempRoute/logoutdevice`) {
if (ParseErrorMessage(error) == "Token generated.") {
console.log("New token generated.")
//refresh occured so repeat last request
Expand Down

0 comments on commit f081aed

Please sign in to comment.