Handle Stale access token for Gmail and update the startup schema repair. Style the kanban for darkmode better
This commit is contained in:
@@ -228,7 +228,15 @@ public sealed class GmailOAuthService : IGmailOAuthService
|
||||
connection.AccessTokenExpiresAt is { } expiresAt &&
|
||||
expiresAt > DateTimeOffset.UtcNow.AddMinutes(1))
|
||||
{
|
||||
return _protector.Unprotect(connection.EncryptedAccessToken);
|
||||
try
|
||||
{
|
||||
return _protector.Unprotect(connection.EncryptedAccessToken);
|
||||
}
|
||||
catch (CryptographicException)
|
||||
{
|
||||
connection.EncryptedAccessToken = null;
|
||||
connection.AccessTokenExpiresAt = null;
|
||||
}
|
||||
}
|
||||
|
||||
string refreshToken;
|
||||
|
||||
Reference in New Issue
Block a user