Sfoglia il codice sorgente

refactor: remove descriptions and comment out key validation in video and image signing methods

Dave 1 mese fa
parent
commit
8edca80ce6

+ 4 - 4
apps/box-mgnt-api/src/mgnt-backend/feature/s3/s3.controller.ts

@@ -140,11 +140,11 @@ export class S3Controller {
   @ApiQuery({
     name: 'key',
     required: true,
-    description: '必须以 mp4/ 开头的 key',
+    description: '',
   })
   @ApiResponse({ status: 200, description: '返回视频播放的签名 URL' })
   async getSignedVideo(@Query('key') key: string) {
-    this.validateKey(key, 'mp4/');
+    // this.validateKey(key, 'mp4/');
     return this.s3Service.getSignedReadUrl(key);
   }
 
@@ -152,11 +152,11 @@ export class S3Controller {
   @ApiQuery({
     name: 'key',
     required: true,
-    description: '必须以 img/ 开头的 key',
+    description: '',
   })
   @ApiResponse({ status: 200, description: '返回图片的签名 URL' })
   async getSignedImage(@Query('key') key: string) {
-    this.validateKey(key, 'img/');
+    // this.validateKey(key, 'img/');
     return this.s3Service.getSignedReadUrl(key);
   }