File tree Expand file tree Collapse file tree
backend/src/entities/company-info Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -515,7 +515,7 @@ export class CompanyInfoController {
515515 @SlugUuid ( 'companyId' ) companyId : string ,
516516 @UploadedFile (
517517 new ParseFilePipeBuilder ( )
518- . addFileTypeValidator ( { fileType : / i m a g e \/ ( p n g | j p e g | j p g | s v g \+ x m l ) / } )
518+ . addFileTypeValidator ( { fileType : / i m a g e \/ ( p n g | j p e g | j p g | s v g \+ x m l ) / , skipMagicNumbersValidation : true } )
519519 . addMaxSizeValidator ( { maxSize : Constants . MAX_COMPANY_LOGO_SIZE } )
520520 . build ( { errorHttpStatusCode : HttpStatus . UNPROCESSABLE_ENTITY } ) ,
521521 )
@@ -567,7 +567,7 @@ export class CompanyInfoController {
567567 @SlugUuid ( 'companyId' ) companyId : string ,
568568 @UploadedFile (
569569 new ParseFilePipeBuilder ( )
570- . addFileTypeValidator ( { fileType : / i m a g e \/ ( p n g | j p e g | j p g | s v g \+ x m l ) / } )
570+ . addFileTypeValidator ( { fileType : / i m a g e \/ ( p n g | j p e g | j p g | s v g \+ x m l ) / , skipMagicNumbersValidation : true } )
571571 . addMaxSizeValidator ( { maxSize : Constants . MAX_COMPANY_FAVICON_SIZE } )
572572 . build ( { errorHttpStatusCode : HttpStatus . UNPROCESSABLE_ENTITY } ) ,
573573 )
You can’t perform that action at this time.
0 commit comments