File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -141,11 +141,14 @@ export class ConnectionManager extends EventEmitter<ConnectionManagerEvents> {
141
141
try {
142
142
await this . state . serviceProvider ?. close ( true ) ;
143
143
} finally {
144
- this . changeState ( "connection-closed" , { tag : "disconnected" } ) ;
144
+ this . changeState ( "connection-closed" , {
145
+ tag : "disconnected" ,
146
+ connectedAtlasCluster : this . state . connectedAtlasCluster ,
147
+ } ) ;
145
148
}
146
149
}
147
150
148
- return { tag : "disconnected" } ;
151
+ return { tag : "disconnected" , connectedAtlasCluster : this . state . connectedAtlasCluster } ;
149
152
}
150
153
151
154
get currentConnectionState ( ) : AnyConnectionState {
Original file line number Diff line number Diff line change @@ -45,7 +45,6 @@ export class ConnectClusterTool extends AtlasToolBase {
45
45
} else {
46
46
return "connected" ;
47
47
}
48
- break ;
49
48
case "connecting" :
50
49
case "disconnected" : // we might still be calling Atlas APIs and not attempted yet to connect to MongoDB, but we are still "connecting"
51
50
return "connecting" ;
@@ -57,7 +56,6 @@ export class ConnectClusterTool extends AtlasToolBase {
57
56
) ;
58
57
return "unknown" ;
59
58
}
60
- return "unknown" ;
61
59
}
62
60
63
61
private async prepareClusterConnection (
You can’t perform that action at this time.
0 commit comments