diff --git a/src/infrastructure/storage/cos-storage.provider.ts b/src/infrastructure/storage/cos-storage.provider.ts index 1d52560..ee6b9d8 100644 --- a/src/infrastructure/storage/cos-storage.provider.ts +++ b/src/infrastructure/storage/cos-storage.provider.ts @@ -33,7 +33,7 @@ export class CosStorageProvider { this.cos = new COS({ SecretId: secretId, SecretKey: secretKey, - Domain: domain, + ...(domain ? { Domain: domain } : {}), Protocol: 'https:', });