When an end user is required to log in again (generation of a fresh auth token), to enhance UX, we want to redirect them back to the page they were on before having to log in again. The server method 'setJWTAndRespond' takes in an optional url for redirection after responding. The client needs to send the url to the server.
When an end user is required to log in again (generation of a fresh auth token), to enhance UX, we want to redirect them back to the page they were on before having to log in again. The server method 'setJWTAndRespond' takes in an optional url for redirection after responding. The client needs to send the url to the server.