diff options
| author | Russell Keith-Magee <russell@keith-magee.com> | 2010-05-08 07:41:22 +0000 |
|---|---|---|
| committer | Russell Keith-Magee <russell@keith-magee.com> | 2010-05-08 07:41:22 +0000 |
| commit | 6b1a2a8e44071a2b7415b3016227d12d382f17f2 (patch) | |
| tree | aedbeb818b3b7e54ac7d74d57648448183d0cd8f /docs | |
| parent | e34ca2b1e214799b2b474dcc2a5f20e80a987d8d (diff) | |
Fixed #13428 -- Corrected the allow_relation behavior of and example router. Thanks to jcd for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@13133 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/topics/db/multi-db.txt | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/docs/topics/db/multi-db.txt b/docs/topics/db/multi-db.txt index 72b5116504..27dc2261ca 100644 --- a/docs/topics/db/multi-db.txt +++ b/docs/topics/db/multi-db.txt @@ -256,7 +256,7 @@ master/slave relationship between the databases ``master``, ``slave1`` and def allow_relation(self, obj1, obj2, **hints): "Allow any relation between two objects in the db pool" db_list = ('master','slave1','slave2') - if obj1 in db_list and obj2 in db_list: + if obj1._state.db in db_list and obj2._state.db in db_list: return True return None |
