Fixed regressions from the last commit.

This commit is contained in:
Akshay Joshi 2021-03-03 11:46:47 +05:30
parent 008bc6da28
commit 8c7417b735
3 changed files with 4 additions and 3 deletions

View File

@ -298,7 +298,7 @@ class DatabaseView(PGChildNodeView):
connected = True
can_drop = can_dis_conn = False
else:
conn = self.manager.connection(dbname, did=row['did'])
conn = self.manager.connection(database=dbname, did=row['did'])
connected = conn.connected()
can_drop = can_dis_conn = True

View File

@ -796,7 +796,7 @@ class TablespaceView(PGChildNodeView):
# a new connection to run the query and fetch the dependents.
is_connected = True
try:
temp_conn = manager.connection(db_row['datname'])
temp_conn = manager.connection(database=db_row['datname'])
is_connected = temp_conn.connected()
if not is_connected:
temp_conn.connect()

View File

@ -365,7 +365,8 @@ WHERE db.oid = {0}""".format(did))
else:
conn = self.connections[conn_info['conn_id']] = Connection(
self, conn_info['conn_id'], conn_info['database'],
conn_info['auto_reconnect'], conn_info['async_'],
auto_reconnect=conn_info['auto_reconnect'],
async_=conn_info['async_'],
use_binary_placeholder=conn_info[
'use_binary_placeholder'],
array_to_string=conn_info['array_to_string']