mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Rewrote ObjectChangeMiddleware to remove the curried handle_deleted_object() function
This commit is contained in:
9
netbox/utilities/querysets.py
Normal file
9
netbox/utilities/querysets.py
Normal file
@@ -0,0 +1,9 @@
|
||||
class DummyQuerySet:
|
||||
"""
|
||||
A fake QuerySet that can be used to cache relationships to objects that have been deleted.
|
||||
"""
|
||||
def __init__(self, queryset):
|
||||
self._cache = [obj for obj in queryset.all()]
|
||||
|
||||
def all(self):
|
||||
return self._cache
|
Reference in New Issue
Block a user