Skip to content
This repository was archived by the owner on Sep 19, 2023. It is now read-only.

Commit 7662726

Browse files
authored
Merge pull request #34 from Yoshiin/yoshin/fix-empty-acceptedMimeType
Fixing a bug where the file is not copied for analyse if the acceptedMimeType option is not present
2 parents dd70705 + 4a7fdd5 commit 7662726

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/reporting.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -293,12 +293,12 @@ async function generateReport(console, httpUrl, matrixFile, filePath, tempDir, s
293293
console.info(`FileType: ${type.mime}`);
294294
return {clean: false, info: 'File type not supported'};
295295
}
296-
try {
297-
fs.copyFileSync(filePath, decryptedFilePath);
298-
} catch (err) {
299-
console.error(err);
300-
throw new ClientError(400, 'Failed to copy file for decryption', 'MCS_MEDIA_FAILED_TO_DECRYPT');
301-
}
296+
}
297+
try {
298+
fs.copyFileSync(filePath, decryptedFilePath);
299+
} catch (err) {
300+
console.error(err);
301+
throw new ClientError(400, 'Failed to copy file for decryption', 'MCS_MEDIA_FAILED_TO_DECRYPT');
302302
}
303303
}
304304

0 commit comments

Comments
 (0)