Skip to content

Commit

Permalink
refactor: update file upload configuration type check in storage module
Browse files Browse the repository at this point in the history
  • Loading branch information
minai621 committed Nov 11, 2024
1 parent 9f79b8f commit 57c0ebd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions backend/src/storage/storage.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import { ConfigService } from "@nestjs/config";
const s3ClientFactory = {
provide: "STORAGE_CLIENT",
useFactory: (configService: ConfigService): S3Client | null => {
const fileUpload = configService.get<boolean | "s3" | "minio">("FILE_UPLOAD");
if (!fileUpload) {
const fileUpload = configService.get<"false" | "s3" | "minio">("FILE_UPLOAD");
if (fileUpload === "false") {
return null;
}
const region = configService.get<string>("AWS_REGION");
Expand Down

0 comments on commit 57c0ebd

Please sign in to comment.