Skip to content

Commit 9a02ae5

Browse files
committed
refactor pushing line number of normal command execution
1 parent 3149e8c commit 9a02ae5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/transformations/execute.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -246,15 +246,15 @@ export async function executeTransformations(
246246
const resultLineNumbers: number[] = [];
247247
if (withRange) {
248248
for (let i = startLineNumber; i <= endLineNumber; i++) {
249-
resultLineNumbers.push(vimState.document.lineAt(i).lineNumber);
249+
resultLineNumbers.push(i);
250250
}
251251
} else {
252252
const selectionList = vimState.editor.selections;
253253
for (const selection of selectionList) {
254254
const { start, end } = selection;
255255

256256
for (let i = start.line; i <= end.line; i++) {
257-
resultLineNumbers.push(vimState.document.lineAt(i).lineNumber);
257+
resultLineNumbers.push(i);
258258
}
259259
}
260260
}

0 commit comments

Comments
 (0)