mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Fix disconnection of new databases. Fixes #2594
This commit is contained in:
committed by
Dave Page
parent
b313cbce0d
commit
acaa79cf6b
@@ -173,11 +173,11 @@ define('pgadmin.node.database', [
|
||||
},
|
||||
/* Disconnect the database */
|
||||
disconnect_database: function(args) {
|
||||
var input = args || {};
|
||||
obj = this,
|
||||
t = pgBrowser.tree,
|
||||
i = input.item || t.selected(),
|
||||
d = i && i.length == 1 ? t.itemData(i) : undefined;
|
||||
var input = args || {},
|
||||
obj = this,
|
||||
t = pgBrowser.tree,
|
||||
i = input.item || t.selected(),
|
||||
d = i && i.length == 1 ? t.itemData(i) : undefined;
|
||||
|
||||
if (!d)
|
||||
return false;
|
||||
@@ -192,8 +192,8 @@ define('pgadmin.node.database', [
|
||||
type:'DELETE',
|
||||
success: function(res) {
|
||||
if (res.success == 1) {
|
||||
var prv_i = t.parent(i);
|
||||
var alertifyWrapper = new AlertifyWrapper();
|
||||
var prv_i = t.parent(i),
|
||||
alertifyWrapper = new AlertifyWrapper();
|
||||
alertifyWrapper.success(res.info);
|
||||
t.removeIcon(i);
|
||||
data.connected = false;
|
||||
|
Reference in New Issue
Block a user