Formatting doesn't work for a file outside editor project folder #324
Labels
enhancement
New feature or request
good first issue
Good for newcomers
help wanted
Extra attention is needed
Environment
Issue
LSP-elixir issue: sublimelsp/LSP-elixir#7
When opening Elixir file outside project-folder, right-clicking within it, and choosing "LSP > Format Document", it fails with exception:
Exception happens because
project_dir
isnil
here:elixir-ls/apps/language_server/lib/language_server/providers/formatting.ex
Line 35 in e50e153
It would be nice if this could be made to work - code formatting shouldn't rely on file being in a project. But if this is not possible, then at the very least this limitation should be documented.
The text was updated successfully, but these errors were encountered: