When bulk-deleting, skip objects which are not "deletable"
whatever that means in context
This commit is contained in:
parent
4ecea891b3
commit
90075b3b65
|
@ -1728,7 +1728,8 @@ class MasterView(View):
|
||||||
def bulk_delete_objects(self, session, objects, progress=None):
|
def bulk_delete_objects(self, session, objects, progress=None):
|
||||||
|
|
||||||
def delete(obj, i):
|
def delete(obj, i):
|
||||||
self.delete_instance(obj)
|
if self.deletable_instance(obj):
|
||||||
|
self.delete_instance(obj)
|
||||||
if i % 1000 == 0:
|
if i % 1000 == 0:
|
||||||
session.flush()
|
session.flush()
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue