diff options
Diffstat (limited to 'src/lib/Bcfg2/Server/Core.py')
-rw-r--r-- | src/lib/Bcfg2/Server/Core.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/lib/Bcfg2/Server/Core.py b/src/lib/Bcfg2/Server/Core.py index 78eed4b3e..59e9254c1 100644 --- a/src/lib/Bcfg2/Server/Core.py +++ b/src/lib/Bcfg2/Server/Core.py @@ -87,11 +87,8 @@ def close_db_connection(func): self.logger.debug("%s: Closing database connection" % threading.current_thread().getName()) - if django.VERSION[0] == 1 and django.VERSION[1] >= 7: - for connection in django.db.connections.all(): - connection.close() - else: - django.db.close_connection() # pylint: disable=E1101 + for connection in django.db.connections.all(): + connection.close() return rv return inner |