diff options
| author | Nick Bruun <nick@bruun.co> | 2013-08-15 20:59:58 +0200 |
|---|---|---|
| committer | Nick Bruun <nick@bruun.co> | 2013-08-15 20:59:58 +0200 |
| commit | b9ef96e73cf2f2613eb6ca96038ef8c4271ac116 (patch) | |
| tree | aff96b820c146d1e682a935b6650b75d86f8cefe /django/utils/functional.py | |
| parent | bc5716fc9ce517c6aaa2b78f311724a335488924 (diff) | |
Regression test and patch for ticket #20924.
Diffstat (limited to 'django/utils/functional.py')
| -rw-r--r-- | django/utils/functional.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/django/utils/functional.py b/django/utils/functional.py index d5d52205d7..465de283e5 100644 --- a/django/utils/functional.py +++ b/django/utils/functional.py @@ -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 |
