Skip to content

Commit 639c324

Browse files
committed
fixes #4631
1 parent dfb58ef commit 639c324

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Rubberduck.Core/AutoComplete/SelfClosingPairs/SelfClosingPairHandler.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,12 @@ private bool HandleInternal(AutoCompleteEventArgs e, CodeString original, SelfCl
124124
);
125125
}
126126

127+
if (original.CaretLine.EndsWith(" ") &&
128+
string.Equals(original.CaretLine, prettified.CaretLine + " ", StringComparison.InvariantCultureIgnoreCase))
129+
{
130+
prettified = original;
131+
}
132+
127133
// if executing the SCP against the prettified code yields no result, we need to bail out.
128134
if (!_scpService.Execute(pair, prettified, e.Character, out result))
129135
{

0 commit comments

Comments
 (0)