Ignore indexed data when trying to reuse old metadata

This commit is contained in:
tcely 2025-05-28 16:37:57 -04:00 committed by GitHub
parent d970733204
commit 0b5a475e03
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -429,6 +429,7 @@ def media_post_delete(sender, instance, **kwargs):
# Re-use the old metadata if it exists
instance_qs = Metadata.objects.filter(
media__isnull=True,
source__isnull=True,
site=old_metadata.get(site_field) or 'Youtube',
key=skipped_media.key,
)