We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9b4744f commit 778d9f7Copy full SHA for 778d9f7
src/renderer/utils/auth/utils.ts
@@ -3,7 +3,7 @@ import { format } from 'date-fns';
3
import semver from 'semver';
4
5
import { APPLICATION } from '../../../shared/constants';
6
-import { logError } from '../../../shared/logger';
+import { logError, logWarn } from '../../../shared/logger';
7
import type {
8
Account,
9
AuthCode,
@@ -179,6 +179,13 @@ export async function refreshAccount(account: Account): Promise<Account> {
179
account.hasRequiredScopes = Constants.AUTH_SCOPE.every((scope) =>
180
accountScopes.includes(scope),
181
);
182
+
183
+ if (!account.hasRequiredScopes) {
184
+ logWarn(
185
+ 'refreshAccount',
186
+ `account for user ${account.user.login} is missing required scopes`,
187
+ );
188
+ }
189
} catch (err) {
190
logError(
191
'refreshAccount',
0 commit comments