diff --git a/src/project.cc b/src/project.cc index 9cd3ce4..f79bd80 100644 --- a/src/project.cc +++ b/src/project.cc @@ -741,7 +741,7 @@ void Project::LanguageProtocol::show_symbols() { else { std::vector rows; std::promise result_processed; - client->write_request(nullptr, "textDocument/documentSymbol", R"("textDocument":{"uri":"file://)" + language_protocol_view->file_path.string() + "\"}", [&result_processed, &rows, locations](const boost::property_tree::ptree &result, bool error) { + client->write_request(language_protocol_view, "textDocument/documentSymbol", R"("textDocument":{"uri":"file://)" + language_protocol_view->file_path.string() + "\"}", [&result_processed, &rows, locations](const boost::property_tree::ptree &result, bool error) { if(!error) { for(auto it = result.begin(); it != result.end(); ++it) { try { diff --git a/src/source_language_protocol.cc b/src/source_language_protocol.cc index 9993e3f..dcfbd05 100644 --- a/src/source_language_protocol.cc +++ b/src/source_language_protocol.cc @@ -860,7 +860,7 @@ void Source::LanguageProtocolView::setup_navigation_and_refactoring() { std::vector> methods; std::promise result_processed; - client->write_request(nullptr, "textDocument/documentSymbol", R"("textDocument":{"uri":"file://)" + file_path.string() + "\"}", [&result_processed, &methods](const boost::property_tree::ptree &result, bool error) { + client->write_request(this, "textDocument/documentSymbol", R"("textDocument":{"uri":"file://)" + file_path.string() + "\"}", [&result_processed, &methods](const boost::property_tree::ptree &result, bool error) { if(!error) { for(auto it = result.begin(); it != result.end(); ++it) { try {