Skip to content

Commit

Permalink
Fixed migrations when limiting set search_path calls. Thanks @bjersey,
Browse files Browse the repository at this point in the history
…@philfriesen, @bjs987. Fixes #253.
  • Loading branch information
bernardopires committed Jul 30, 2015
1 parent 4654fc3 commit 8865160
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tenant_schemas/postgresql_backend/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@ def __init__(self, *args, **kwargs):
self.introspection = DatabaseSchemaIntrospection(self)
self.set_schema_to_public()

def close(self):
self.search_path_set = False
super(DatabaseWrapper, self).close()

def set_tenant(self, tenant, include_public=True):
"""
Main API method to current database schema,
Expand Down

0 comments on commit 8865160

Please sign in to comment.