From 6221e9975892da8e74352d079dc56564b89b7aae Mon Sep 17 00:00:00 2001 From: minchodang Date: Wed, 4 Sep 2024 23:44:54 +0900 Subject: [PATCH] =?UTF-8?q?Fix:=20supabase=20=EB=AA=A8=EB=93=88=20?= =?UTF-8?q?=EA=B5=90=EC=B2=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app.module.ts | 15 +++++++-------- .../supabase.module.ts} | 0 src/modules/auth/auth.module.ts | 4 ++-- src/modules/test/test.module.ts | 2 +- src/modules/user/user.controller.ts | 2 +- src/modules/user/user.module.ts | 4 ++-- 6 files changed, 13 insertions(+), 14 deletions(-) rename src/database/{dynamodb/dynamodb.module.ts => supabase/supabase.module.ts} (100%) diff --git a/src/app.module.ts b/src/app.module.ts index 195040d..db31709 100644 --- a/src/app.module.ts +++ b/src/app.module.ts @@ -1,12 +1,11 @@ -import { Module } from "@nestjs/common"; -import { HealthCheckController } from "./modules/health-check/health-check.controller"; -import { DynamoDBModule } from "./database/dynamodb/dynamodb.module"; -import { UserModule } from "./modules/user/user.module"; -import { AuthModule } from "./modules/auth/auth.module"; -import { TestModule } from "./modules/test/test.module"; - +import { Module } from '@nestjs/common'; +import { HealthCheckController } from './modules/health-check/health-check.controller'; +import { UserModule } from './modules/user/user.module'; +import { AuthModule } from './modules/auth/auth.module'; +import { TestModule } from './modules/test/test.module'; +import { SupabaseModule } from './database/supabase/supabase.module'; @Module({ - imports: [DynamoDBModule, UserModule, AuthModule, TestModule], + imports: [SupabaseModule, UserModule, AuthModule, TestModule], controllers: [HealthCheckController], providers: [], }) diff --git a/src/database/dynamodb/dynamodb.module.ts b/src/database/supabase/supabase.module.ts similarity index 100% rename from src/database/dynamodb/dynamodb.module.ts rename to src/database/supabase/supabase.module.ts diff --git a/src/modules/auth/auth.module.ts b/src/modules/auth/auth.module.ts index 21b261d..282ac33 100644 --- a/src/modules/auth/auth.module.ts +++ b/src/modules/auth/auth.module.ts @@ -3,7 +3,6 @@ import { JwtModule } from '@nestjs/jwt'; import { AuthService } from './auth.service'; import { AuthRepository } from './auth.repository'; import { AuthController } from './auth.controller'; -import { DynamoDBModule } from '../../database/dynamodb/dynamodb.module'; import { JwtStrategy } from '../../auth/strategy/jwt.strategy'; import { PassportModule } from '@nestjs/passport'; import { UserModule } from '../user/user.module'; @@ -12,10 +11,11 @@ import { UserService } from '../user/user.service'; import { UserRepository } from '../user/user.repository'; import { GoogleStrategy } from 'src/auth/strategy/google.strategy'; import { jwtConstants } from 'src/core/config/jwt'; +import { SupabaseModule } from 'src/database/supabase/supabase.module'; @Module({ imports: [ - DynamoDBModule, + SupabaseModule, PassportModule, JwtModule.register({ secret: process.env.JWT_SECRET, diff --git a/src/modules/test/test.module.ts b/src/modules/test/test.module.ts index 776ba04..a394670 100644 --- a/src/modules/test/test.module.ts +++ b/src/modules/test/test.module.ts @@ -2,7 +2,7 @@ import { Module } from '@nestjs/common'; import { TestService } from './test.service'; import { TestRepository } from './test.repository'; import { TestController } from './test.controller'; -import { DynamoDBModule } from '../../database/dynamodb/dynamodb.module'; +import { DynamoDBModule } from '../../database/supabase/supabase.module'; @Module({ imports: [DynamoDBModule], diff --git a/src/modules/user/user.controller.ts b/src/modules/user/user.controller.ts index 480fffb..cd768d0 100644 --- a/src/modules/user/user.controller.ts +++ b/src/modules/user/user.controller.ts @@ -235,7 +235,7 @@ export class UserController { }) @HttpCode(HttpStatus.OK) async geteUserTestList( - @Request() req: any, + @Request() req, @Query() query: GetUserTestListQueryDto, ) { const id = req.user.id; diff --git a/src/modules/user/user.module.ts b/src/modules/user/user.module.ts index d27952e..cc5d4d9 100644 --- a/src/modules/user/user.module.ts +++ b/src/modules/user/user.module.ts @@ -2,11 +2,11 @@ import { Module } from '@nestjs/common'; import { UserService } from './user.service'; import { UserRepository } from './user.repository'; import { UserController } from './user.controller'; -import { DynamoDBModule } from '../../database/dynamodb/dynamodb.module'; import { AuthModule } from '../auth/auth.module'; +import { SupabaseModule } from 'src/database/supabase/supabase.module'; @Module({ - imports: [DynamoDBModule, AuthModule], + imports: [SupabaseModule, AuthModule], controllers: [UserController], providers: [UserService, UserRepository], exports: [UserService, UserRepository],