fix(microsoft): show relogin dialog when grant expired. Closes #1691.

This commit is contained in:
huanghongxun 2022-09-03 23:35:09 +08:00
parent 0c7b0f285e
commit a6b26a0cd9

View File

@ -181,7 +181,8 @@ public class OAuth {
switch (response.error) { switch (response.error) {
case "invalid_grant": case "invalid_grant":
if (response.errorDescription.contains("The user must sign in again and if needed grant the client application access to the requested scope")) { if (response.errorDescription.contains("The user must sign in again and if needed grant the client application access to the requested scope") ||
response.errorDescription.contains("The user could not be authenticated as the grant is expired")) {
throw new CredentialExpiredException(); throw new CredentialExpiredException();
} }
break; break;