🐛 bugs

This commit is contained in:
2021-04-28 14:32:58 -07:00
parent ce98e09bf1
commit 294e124656
3 changed files with 4 additions and 4 deletions

View File

@@ -42,6 +42,7 @@ export const unrar = async (
const extractor = await unrarer.createExtractorFromData({ data: fileBuffer });
switch (extractionOptions.extractTarget) {
case "cover":
debugger;
const list = extractor.getFileList();
const fileHeaders = [...list.fileHeaders];
const file = extractor.extract({ files: [fileHeaders[0].name] });
@@ -69,6 +70,7 @@ export const unrar = async (
reject(error);
}
});
case "all":
const files = extractor.extract({});
const extractedFiles = [...files.files];
@@ -172,7 +174,6 @@ export const extractArchive = async (
| IExtractedComicBookCoverFile[]
| IExtractComicBookCoverErrorResponse
> => {
console.log(extractionOptions);
switch (extractionOptions.folderDetails.extension) {
case ".cbz":
return await unzip(extractionOptions);