diff --git a/dokuWikiUploader/uploader.py b/dokuWikiUploader/uploader.py index 2ccf9db..1c0ff23 100644 --- a/dokuWikiUploader/uploader.py +++ b/dokuWikiUploader/uploader.py @@ -181,14 +181,15 @@ def upload(args: dict): print(f"File {file_in_item['name']} already exists in {identifier_remote}.") print(f"Uploading {len(filedict)} files...") print(md_init) - r = item.upload( - files=filedict, - metadata=md_init, - access_key=access_key, - secret_key=secret_key, - verbose=True, - queue_derive=False, - ) + if filedict: + item.upload( + files=filedict, + metadata=md_init, + access_key=access_key, + secret_key=secret_key, + verbose=True, + queue_derive=False, + ) print(f"Uploading {len(filedict)} files: Done.\n")