From 0c13ca7dcac4e41a7a26fd5d4f13c492e2fb4ded Mon Sep 17 00:00:00 2001 From: Mir Arif Hasan Date: Thu, 4 Jan 2024 16:45:25 +0600 Subject: [PATCH] feat: update configService in strategy file --- .../hoppscotch-backend/src/auth/strategies/github.strategy.ts | 4 ++-- .../hoppscotch-backend/src/auth/strategies/google.strategy.ts | 4 ++-- .../src/auth/strategies/microsoft.strategy.ts | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/hoppscotch-backend/src/auth/strategies/github.strategy.ts b/packages/hoppscotch-backend/src/auth/strategies/github.strategy.ts index 3f81e41e0..4c2d3b1ea 100644 --- a/packages/hoppscotch-backend/src/auth/strategies/github.strategy.ts +++ b/packages/hoppscotch-backend/src/auth/strategies/github.strategy.ts @@ -17,8 +17,8 @@ export class GithubStrategy extends PassportStrategy(Strategy) { super({ clientID: configService.get('INFRA.GITHUB_CLIENT_ID'), clientSecret: configService.get('INFRA.GITHUB_CLIENT_SECRET'), - callbackURL: configService.get('GITHUB_CALLBACK_URL'), - scope: [configService.get('GITHUB_SCOPE')], + callbackURL: configService.get('INFRA.GITHUB_CALLBACK_URL'), + scope: [configService.get('INFRA.GITHUB_SCOPE')], store: true, }); } diff --git a/packages/hoppscotch-backend/src/auth/strategies/google.strategy.ts b/packages/hoppscotch-backend/src/auth/strategies/google.strategy.ts index 2a1b92497..52bb77764 100644 --- a/packages/hoppscotch-backend/src/auth/strategies/google.strategy.ts +++ b/packages/hoppscotch-backend/src/auth/strategies/google.strategy.ts @@ -17,8 +17,8 @@ export class GoogleStrategy extends PassportStrategy(Strategy) { super({ clientID: configService.get('INFRA.GOOGLE_CLIENT_ID'), clientSecret: configService.get('INFRA.GOOGLE_CLIENT_SECRET'), - callbackURL: configService.get('GOOGLE_CALLBACK_URL'), - scope: configService.get('GOOGLE_SCOPE').split(','), + callbackURL: configService.get('INFRA.GOOGLE_CALLBACK_URL'), + scope: configService.get('INFRA.GOOGLE_SCOPE').split(','), passReqToCallback: true, store: true, }); diff --git a/packages/hoppscotch-backend/src/auth/strategies/microsoft.strategy.ts b/packages/hoppscotch-backend/src/auth/strategies/microsoft.strategy.ts index a174e2b32..9f171d46e 100644 --- a/packages/hoppscotch-backend/src/auth/strategies/microsoft.strategy.ts +++ b/packages/hoppscotch-backend/src/auth/strategies/microsoft.strategy.ts @@ -17,8 +17,8 @@ export class MicrosoftStrategy extends PassportStrategy(Strategy) { super({ clientID: configService.get('INFRA.MICROSOFT_CLIENT_ID'), clientSecret: configService.get('INFRA.MICROSOFT_CLIENT_SECRET'), - callbackURL: configService.get('MICROSOFT_CALLBACK_URL'), - scope: [configService.get('MICROSOFT_SCOPE')], + callbackURL: configService.get('INFRA.MICROSOFT_CALLBACK_URL'), + scope: [configService.get('INFRA.MICROSOFT_SCOPE')], tenant: configService.get('MICROSOFT_TENANT'), store: true, });