diff --git a/api/funkwhale_api/common/management/commands/inplace_to_s3.py b/api/funkwhale_api/common/management/commands/inplace_to_s3.py index c9fca94ce..bc0b753bc 100644 --- a/api/funkwhale_api/common/management/commands/inplace_to_s3.py +++ b/api/funkwhale_api/common/management/commands/inplace_to_s3.py @@ -73,7 +73,7 @@ class Command(BaseCommand): self.stdout.write(f"Found {to_change.count()} uploads to update.") - target = options["target"] if options["target"] else options["source"] + target = options.get("target", options["source"]) for upl in to_change: upl.audio_file = str(upl.source).replace(str(prefix), str(target))