From 1b9d83f367a43da9f0b21daa11e7e2ebd559a9f6 Mon Sep 17 00:00:00 2001 From: Alex Ling Date: Mon, 1 Jun 2020 04:54:28 +0000 Subject: [PATCH] Report if archive is not readable #49 --- src/library.cr | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/library.cr b/src/library.cr index 2520f6c..6a877a8 100644 --- a/src/library.cr +++ b/src/library.cr @@ -114,6 +114,11 @@ class Title next end if [".zip", ".cbz", ".rar", ".cbr"].includes? File.extname path + unless File.readable? path + Logger.warn "File #{path} is not readable. Please make sure the " \ + "file permission is configured correctly." + next + end archive_exception = validate_archive path unless archive_exception.nil? Logger.warn "File #{path} is corrupted or is not a valid archive. " \