Skip to content

Commit

Permalink
Merge af09889 into 43b4e5c
Browse files Browse the repository at this point in the history
  • Loading branch information
Aditya Bist committed Jan 21, 2020
2 parents 43b4e5c + af09889 commit c14bdf2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
10 changes: 5 additions & 5 deletions src/controllers/mainController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -223,32 +223,32 @@ export default class MainController implements vscode.Disposable {
this._context.subscriptions.push(
vscode.commands.registerCommand(
Constants.cmdScriptSelect, async (node: TreeNodeInfo) => {
this.scriptNode(node, ScriptOperation.Select, true);
await this.scriptNode(node, ScriptOperation.Select, true);
}));

// Script as Create
this._context.subscriptions.push(
vscode.commands.registerCommand(
Constants.cmdScriptCreate, async (node: TreeNodeInfo) =>
this.scriptNode(node, ScriptOperation.Create)));
await this.scriptNode(node, ScriptOperation.Create)));

// Script as Drop
this._context.subscriptions.push(
vscode.commands.registerCommand(
Constants.cmdScriptDelete, async (node: TreeNodeInfo) =>
this.scriptNode(node, ScriptOperation.Delete)));
await this.scriptNode(node, ScriptOperation.Delete)));

// Script as Execute
this._context.subscriptions.push(
vscode.commands.registerCommand(
Constants.cmdScriptExecute, async (node: TreeNodeInfo) =>
this.scriptNode(node, ScriptOperation.Execute)));
await this.scriptNode(node, ScriptOperation.Execute)));

// Script as Alter
this._context.subscriptions.push(
vscode.commands.registerCommand(
Constants.cmdScriptAlter, async (node: TreeNodeInfo) =>
this.scriptNode(node, ScriptOperation.Alter)));
await this.scriptNode(node, ScriptOperation.Alter)));

// Add handlers for VS Code generated commands
this._vscodeWrapper.onDidCloseTextDocument(async (params) => await this.onDidCloseTextDocument(params));
Expand Down
5 changes: 2 additions & 3 deletions src/objectExplorer/objectExplorerService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -133,10 +133,9 @@ export class ObjectExplorerService {
const handler = (result: ExpandResponse) => {
if (result && result.nodes) {
const credentials = self._sessionIdToConnectionCredentialsMap.get(result.sessionId);
let parentNode = self._rootTreeNodeArray.find(n => n.nodePath === result.nodePath);
const children = result.nodes.map(node => TreeNodeInfo.fromNodeInfo(node, result.sessionId,
parentNode, credentials));
self._treeNodeToChildrenMap.set(parentNode, children);
self._currentNode, credentials));
self._treeNodeToChildrenMap.set(self._currentNode, children);
const expandParams: ExpandParams = {
sessionId: result.sessionId,
nodePath: result.nodePath
Expand Down

0 comments on commit c14bdf2

Please sign in to comment.