optional database name option (#17538)

* optional database name option

* object explorer connection title

* revert unexpected change

* bug fixes
This commit is contained in:
Alan Ren
2021-10-29 16:37:35 -07:00
committed by GitHub
parent ce8f1156b1
commit b48f392ab2
5 changed files with 45 additions and 77 deletions

View File

@@ -791,6 +791,11 @@ export class ListDatabasesActionItem extends Disposable implements IActionViewIt
}
private updateConnection(databaseName: string): void {
// Ignore if the database name is not provided, this happens when the query editor connection is changed to
// a provider that does not support database.
if (!databaseName) {
return;
}
this._isConnected = true;
this._currentDatabaseName = databaseName;
// Set the value immediately to the initial database so the user can see that, and then