fix two typos

This commit is contained in:
Laura Klünder 2024-11-29 21:27:35 +01:00
parent 3b50c6f9dd
commit eaffd55718
2 changed files with 2 additions and 2 deletions

View file

@ -186,7 +186,7 @@ class ChangeProblems(BaseSchema):
model_name: problem_objects for
model_name, problem_objects in (
(model_name, {pk: obj for pk, obj in problem_objects.items() if obj.clean()})
for model_name, problem_objects in self.objects_items()
for model_name, problem_objects in self.objects.items()
)
if problem_objects
}

View file

@ -463,7 +463,7 @@ class ChangeSet(models.Model):
"""
cache_key = '%s:changes_as_operations' % self.cache_key_by_changes
changes_as_operations = cache.get(cache_key)
if changes_as_operations:
if not changes_as_operations:
changes_as_operations = self.changes.as_operations
cache.set(cache_key, changes_as_operations, 900)
return changes_as_operations