mirror of
https://github.com/HMCL-dev/HMCL.git
synced 2025-09-17 15:57:18 -04:00
fix(microsoft): show relogin dialog when grant expired. Closes #1691.
This commit is contained in:
parent
0c7b0f285e
commit
a6b26a0cd9
@ -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;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user