From 09c0f1b11382425bed999bf30226e5a0b89197c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Skyler=20M=C3=A4ntysaari?= Date: Wed, 25 Jan 2023 01:34:34 +0200 Subject: [PATCH] Better comment --- server/apps/immich/src/config/asset-upload.config.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/server/apps/immich/src/config/asset-upload.config.ts b/server/apps/immich/src/config/asset-upload.config.ts index 1a9c086d5a..4fa6164801 100644 --- a/server/apps/immich/src/config/asset-upload.config.ts +++ b/server/apps/immich/src/config/asset-upload.config.ts @@ -26,7 +26,9 @@ function fileFilter(req: Request, file: any, cb: any) { if (!req.user) { return cb(new UnauthorizedException()); } - // TODO: Create new API endpoint for mimetypes and use that here. + // TODO: Create new API endpoint for mimetypes and use that here as browser's + // file mimetype is not to be trusted blindly. + // Reference about issue with it: https://stackoverflow.com/questions/26149389/mime-type-missing-for-rar-and-tar/26222177#26222177 cb(null, true); //if ( // file.mimetype.match(