Fixes from tests

This commit is contained in:
tcely authored and GitHub committed 2025-03-01 09:39:54 -05:00
1 parent 189569cc82
commit b520d75f20
1 file changed
+2 -2
+2 -2
View File
@@ -776,8 +776,8 @@ class Media(models.Model):
def save(self, force_insert=False, force_update=False, using=None, update_fields=None):
# Correct the path after a source is renamed
if self.downloaded and not self.media_file_exists:
fp_list = list(self.filepath)
if self.created and self.downloaded and not self.media_file_exists:
fp_list = list((self.filepath,))
if self.media_file:
fp_list.append(self.filepath.parent / Path(self.media_file.path).name)
for filepath in fp_list: