fix: remove redundant conditional operator for file assignment (#2060)

This commit is contained in:
jay98
2025-10-14 20:05:41 +05:30
committed by GitHub
parent ce32dd2907
commit 835d71727c

View File

@@ -101,7 +101,7 @@ export const FileUpload = ({
const filesToUpload = multiple ? acceptedFiles : [acceptedFiles[0]];
onUpload(filesToUpload);
const file = multiple ? acceptedFiles[0] : acceptedFiles[0];
const file = acceptedFiles[0];
setCurrentFile(file);
if (showPreview && file.type.startsWith('image/')) {