This commit is contained in:
syuilo 2022-09-24 17:13:09 +09:00
parent fd5976f378
commit 7670f364e3
2 changed files with 7 additions and 7 deletions

View File

@ -80,11 +80,11 @@ export class DiscordServerService {
if (meta.enableDiscordIntegration) {
return new OAuth2(
meta.discordClientId!,
meta.discordClientSecret!,
'https://discord.com/',
'api/oauth2/authorize',
'api/oauth2/token');
meta.discordClientId!,
meta.discordClientSecret!,
'https://discord.com/',
'api/oauth2/authorize',
'api/oauth2/token');
} else {
return null;
}

View File

@ -167,7 +167,7 @@ export class GithubServerService {
return;
}
const { accessToken } = await new Promise<any>((res, rej) =>
const { accessToken } = await new Promise<{ accessToken: string }>((res, rej) =>
oauth2!.getOAuthAccessToken(code, {
redirect_uri,
}, (err, accessToken, refresh, result) => {
@ -219,7 +219,7 @@ export class GithubServerService {
return;
}
const { accessToken } = await new Promise<any>((res, rej) =>
const { accessToken } = await new Promise<{ accessToken: string }>((res, rej) =>
oauth2!.getOAuthAccessToken(
code,
{ redirect_uri },