From 41d7515f853c59627177a2d654415c5515ac3586 Mon Sep 17 00:00:00 2001 From: MeiMei <30769358+mei23@users.noreply.github.com> Date: Sat, 6 Feb 2021 11:44:46 +0900 Subject: [PATCH] =?UTF-8?q?discordapp.com=20=E2=86=92=20discord.com=20(#71?= =?UTF-8?q?40)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/client/pages/settings/integration.vue | 2 +- src/server/api/service/discord.ts | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/client/pages/settings/integration.vue b/src/client/pages/settings/integration.vue index 4516f490d..7ae1f5e01 100644 --- a/src/client/pages/settings/integration.vue +++ b/src/client/pages/settings/integration.vue @@ -9,7 +9,7 @@
Discord
-

{{ $ts.connectedTo }}: @{{ integrations.discord.username }}#{{ integrations.discord.discriminator }}

+

{{ $ts.connectedTo }}: @{{ integrations.discord.username }}#{{ integrations.discord.discriminator }}

{{ $ts.disconnectSerice }} {{ $ts.connectSerice }}
diff --git a/src/server/api/service/discord.ts b/src/server/api/service/discord.ts index a5ad18d99..007458066 100644 --- a/src/server/api/service/discord.ts +++ b/src/server/api/service/discord.ts @@ -70,7 +70,7 @@ async function getOAuth2() { return new OAuth2( meta.discordClientId!, meta.discordClientSecret!, - 'https://discordapp.com/', + 'https://discord.com/', 'api/oauth2/authorize', 'api/oauth2/token'); } else { @@ -174,7 +174,7 @@ router.get('/dc/cb', async ctx => { } })); - const { id, username, discriminator } = await getJson('https://discordapp.com/api/users/@me', '*/*', 10 * 1000, { + const { id, username, discriminator } = await getJson('https://discord.com/api/users/@me', '*/*', 10 * 1000, { 'Authorization': `Bearer ${accessToken}`, }); @@ -245,7 +245,7 @@ router.get('/dc/cb', async ctx => { } })); - const { id, username, discriminator } = await getJson('https://discordapp.com/api/users/@me', '*/*', 10 * 1000, { + const { id, username, discriminator } = await getJson('https://discord.com/api/users/@me', '*/*', 10 * 1000, { 'Authorization': `Bearer ${accessToken}`, }); if (!id || !username || !discriminator) {