diff --git a/cps/editbooks.py b/cps/editbooks.py index d66763bf..2204ce1e 100644 --- a/cps/editbooks.py +++ b/cps/editbooks.py @@ -453,7 +453,7 @@ def upload_single_file(request, book, book_id): "" + uploadText + "") return uploader.process( - saved_filename, *os.path.splitext(requested_file.filename)) + saved_filename, *os.path.splitext(requested_file.filename), config.config_rarfile_location) def upload_cover(request, book): diff --git a/cps/helper.py b/cps/helper.py index 435b1322..c89bdf3d 100644 --- a/cps/helper.py +++ b/cps/helper.py @@ -292,6 +292,7 @@ def delete_book_file(book, calibrepath, book_format=None): for file in os.listdir(path): if file.upper().endswith("."+book_format): os.remove(os.path.join(path, file)) + return True, None else: if os.path.isdir(path): if len(next(os.walk(path))[1]):