From a256ce7733b4af919e03fce2cefaebb450b7bc90 Mon Sep 17 00:00:00 2001 From: Tim-Oliver Husser Date: Thu, 28 Apr 2022 13:42:36 +0200 Subject: [PATCH] command for deleting files --- pyobs_archive/api/management/commands/delete.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyobs_archive/api/management/commands/delete.py b/pyobs_archive/api/management/commands/delete.py index 8a89cc3..cd09b02 100644 --- a/pyobs_archive/api/management/commands/delete.py +++ b/pyobs_archive/api/management/commands/delete.py @@ -35,7 +35,7 @@ def handle(self, *args, files: list = None, **options): for d in to_delete: # get filename root = settings.ARCHIVE_ROOT - filename = os.path.join(root, frame.path, frame.basename + '.fits.fz') + filename = os.path.join(root, d.path, d.basename + '.fits.fz') # delete file os.remove(filename)