From 8174a9ef106740eb32151e47dad21a999f70b595 Mon Sep 17 00:00:00 2001 From: jlaine Date: Mon, 11 Apr 2011 12:40:43 +0000 Subject: [PATCH] do not define queryset.delete(), the base implementation works git-svn-id: https://svn.bolloretelecom.eu/opensource/django-ldapdb/trunk@1036 e071eeec-0327-468d-9b6a-08194a12b294 --- ldapdb/models/query.py | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/ldapdb/models/query.py b/ldapdb/models/query.py index 6b1c223..e84748c 100644 --- a/ldapdb/models/query.py +++ b/ldapdb/models/query.py @@ -93,20 +93,3 @@ class QuerySet(BaseQuerySet): query = Query(model, WhereNode) super(QuerySet, self).__init__(model=model, query=query, using=using) - def delete(self): - "Bulk deletion." - connection = connections[self.db] - try: - vals = connection.search_s( - self.model.base_dn, - self.model.search_scope, - filterstr=compiler.query_as_ldap(self.query), - attrlist=[], - ) - except ldap.NO_SUCH_OBJECT: - return - - # FIXME : there is probably a more efficient way to do this - for dn, attrs in vals: - connection.delete_s(dn) - -- 2.30.2