diff options
| author | Alex Gaynor <alex.gaynor@gmail.com> | 2013-07-08 10:32:04 +1000 |
|---|---|---|
| committer | Alex Gaynor <alex.gaynor@gmail.com> | 2013-07-08 10:32:04 +1000 |
| commit | 0b69a755029f8a8ba6005b9d77be8132a7bc0fb3 (patch) | |
| tree | 6df294868119639180a0795c591f9ebeadfa0dfc | |
| parent | df3d7e66daedc2d4be8b7ca2f5046ac80e0297f8 (diff) | |
Fixed a bug I introduced in my previosu ommit.
| -rw-r--r-- | django/db/__init__.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/django/db/__init__.py b/django/db/__init__.py index 0d7fbe2a34..72adf60d66 100644 --- a/django/db/__init__.py +++ b/django/db/__init__.py @@ -39,8 +39,15 @@ class DefaultConnectionProxy(object): def __delattr__(self, name): return delattr(connections[DEFAULT_DB_ALIAS], name) + def __eq__(self, other): + return connections[DEFAULT_DB_ALIAS] == other + + def __ne__(self, other): + return connections[DEFAULT_DB_ALIAS] != other + connection = DefaultConnectionProxy() + class DefaultBackendProxy(object): """ Temporary proxy class used during deprecation period of the `backend` module |
