fix panics (#13554)

Release Notes:

- Fixed a panic when editing HTML near the end of a file
- Fixed a panic when editing settings.json from inside the .zed
directory
cd81dad2faConrad Irwin committed on 6/26/2024, 8:32:16 PM· committed by GitHubparent3a08d7a
2 files changedLine totals unavailable