mirror of
https://github.com/gchq/CyberChef.git
synced 2024-11-16 17:08:31 +01:00
Remove no file extension error
This commit is contained in:
parent
0f87c70cee
commit
2d95092479
1 changed files with 1 additions and 5 deletions
|
@ -26,10 +26,6 @@ self.addEventListener("message", function(e) {
|
||||||
log.error("No filename was passed to the ZipWorker");
|
log.error("No filename was passed to the ZipWorker");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!r.hasOwnProperty("fileExtension")) {
|
|
||||||
log.error("No file extension was passed to the ZipWorker");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
self.zipFiles(r.outputs, r.filename, r.fileExtension);
|
self.zipFiles(r.outputs, r.filename, r.fileExtension);
|
||||||
});
|
});
|
||||||
|
@ -55,7 +51,7 @@ self.zipFiles = async function(outputs, filename, fileExtension) {
|
||||||
const cloned = new Dish(outputs[iNum].data.dish);
|
const cloned = new Dish(outputs[iNum].data.dish);
|
||||||
const output = new Uint8Array(await cloned.get(Dish.ARRAY_BUFFER));
|
const output = new Uint8Array(await cloned.get(Dish.ARRAY_BUFFER));
|
||||||
|
|
||||||
if (fileExtension === "") {
|
if (fileExtension === undefined || fileExtension === "") {
|
||||||
// Detect automatically
|
// Detect automatically
|
||||||
const types = detectFileType(output);
|
const types = detectFileType(output);
|
||||||
if (!types.length) {
|
if (!types.length) {
|
||||||
|
|
Loading…
Reference in a new issue