Ensure all creations of directories create the parents too (#5711)

This commit is contained in:
Trenton H
2024-02-10 11:02:40 -08:00
committed by GitHub
parent 0b1523f4e5
commit 13201dbfff
11 changed files with 22 additions and 38 deletions

View File

@@ -243,9 +243,9 @@ class Command(BaseCommand):
) from e
def _import_files_from_manifest(self, progress_bar_disable):
os.makedirs(settings.ORIGINALS_DIR, exist_ok=True)
os.makedirs(settings.THUMBNAIL_DIR, exist_ok=True)
os.makedirs(settings.ARCHIVE_DIR, exist_ok=True)
settings.ORIGINALS_DIR.mkdir(parents=True, exist_ok=True)
settings.THUMBNAIL_DIR.mkdir(parents=True, exist_ok=True)
settings.ARCHIVE_DIR.mkdir(parents=True, exist_ok=True)
self.stdout.write("Copy files into paperless...")