221: Fix on enter r=matklad a=aochagavia

Fixes #219

Co-authored-by: Adolfo Ochagavía <aochagavia92@gmail.com>
This commit is contained in:
bors[bot] 2018-11-09 12:13:50 +00:00
commit 5a9150df9b

View File

@ -12,14 +12,14 @@ interface FileSystemEdit {
export interface SourceChange {
label: string;
SourceFileNodeEdits: lc.TextDocumentEdit[];
sourceFileEdits: lc.TextDocumentEdit[];
fileSystemEdits: FileSystemEdit[];
cursorPosition?: lc.TextDocumentPositionParams;
}
export async function handle(change: SourceChange) {
const wsEdit = new vscode.WorkspaceEdit();
for (const sourceEdit of change.SourceFileNodeEdits) {
for (const sourceEdit of change.sourceFileEdits) {
const uri = Server.client.protocol2CodeConverter.asUri(
sourceEdit.textDocument.uri
);