Fix language server causing random crashes when `use_threads` is enabled
clang-format
nullptr
Ref
find
contains/has