Fixes the match-indentation function on files where there is no detected indentation.
For example, if a user tries to edit a file that just contains "hello", we should not assume the indentation for the file is 0 and then update the incoming response to match that.
[!NOTE]
Some files may genuinely have 0 indentation, and this may be correct behaviour. However, it is far more reliable to just assume the LLM has gotten this right here, rather than handle different edge cases.
Test plan
Create a file that just contains "hello" (no indentation)
Select all of "hello" and start an edit, e.g. "write a merge sort function"
Check that the edit has some indentation, and is not all set to 0 indent
Description
Fixes the
match-indentation
function on files where there is no detected indentation.For example, if a user tries to edit a file that just contains "hello", we should not assume the indentation for the file is
0
and then update the incoming response to match that.Test plan