mirror of
https://github.com/django/django.git
synced 2025-09-17 16:05:54 +00:00
Regression test and patch for ticket #20924.
This commit is contained in:
parent
bc5716fc9c
commit
b9ef96e73c
2 changed files with 21 additions and 0 deletions
|
@ -270,6 +270,14 @@ class LazyObject(object):
|
|||
def __delitem__(self, key):
|
||||
del self[key]
|
||||
|
||||
@new_method_proxy
|
||||
def __len__(self):
|
||||
return len(self)
|
||||
|
||||
@new_method_proxy
|
||||
def __contains__(self, key):
|
||||
return key in self
|
||||
|
||||
|
||||
# Workaround for http://bugs.python.org/issue12370
|
||||
_super = super
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue