mirror of
https://github.com/Microsoft/vscode
synced 2024-10-12 06:17:18 +00:00
Revert "Fixed comment"
This reverts commit 4b3e76abc170276a160f3d86ab424e9a40523d7d.
This commit is contained in:
parent
a7a15df4ca
commit
fd0116b8f6
|
@ -153,8 +153,7 @@ function pathToReplaceRange(valueBeforeCursor: string, fullValue: string, fullVa
|
||||||
// Find the last slash before cursor, and calculate the start of replace range from there
|
// Find the last slash before cursor, and calculate the start of replace range from there
|
||||||
const valueAfterLastSlash = fullValue.slice(lastIndexOfSlash + 1);
|
const valueAfterLastSlash = fullValue.slice(lastIndexOfSlash + 1);
|
||||||
const startPos = shiftPosition(fullValueRange.end, -valueAfterLastSlash.length);
|
const startPos = shiftPosition(fullValueRange.end, -valueAfterLastSlash.length);
|
||||||
|
// If whitespace exists, replace until it
|
||||||
// If whitespace exists, replace until it is gone.
|
|
||||||
const whitespaceIndex = valueAfterLastSlash.indexOf(' ');
|
const whitespaceIndex = valueAfterLastSlash.indexOf(' ');
|
||||||
if (whitespaceIndex === -1) {
|
if (whitespaceIndex === -1) {
|
||||||
return Range.create(startPos, fullValueRange.end);
|
return Range.create(startPos, fullValueRange.end);
|
||||||
|
|
Loading…
Reference in a new issue