We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 686772c commit 23c529aCopy full SHA for 23c529a
django/db/models/sql/query.py
@@ -241,7 +241,8 @@ def sql_with_params(self):
241
return self.get_compiler(DEFAULT_DB_ALIAS).as_sql()
242
243
def __deepcopy__(self, memo):
244
- result = self.clone(memo=memo)
+ """Limit the amount of work when a Query is deepcopied."""
245
+ result = self.clone()
246
memo[id(self)] = result
247
return result
248
@@ -263,7 +264,7 @@ def get_meta(self):
263
264
"""
265
return self.model._meta
266
- def clone(self, klass=None, memo=None, **kwargs):
267
+ def clone(self, klass=None, **kwargs):
268
269
Create a copy of the current instance. The 'kwargs' parameter can be
270
used by clients to update attributes after copying has taken place.
0 commit comments