diff options
Diffstat (limited to 'django/db')
| -rw-r--r-- | django/db/utils.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/django/db/utils.py b/django/db/utils.py index a876974c51..1b3218e34c 100644 --- a/django/db/utils.py +++ b/django/db/utils.py @@ -121,3 +121,10 @@ class ConnectionRouter(object): if allow is not None: return allow return obj1._state.db == obj2._state.db + + def allow_syncdb(self, db, model): + for router in self.routers: + allow = router.allow_syncdb(db, model) + if allow is not None: + return allow + return True |
