From 2c1f3596d14741d2103fdc6d0092e633f733343e Mon Sep 17 00:00:00 2001 From: Yingchi Long Date: Sun, 10 Sep 2023 14:37:23 +0800 Subject: [PATCH] nixd/Server/format: suppress error popups Fixes: #246 --- nixd/lib/Server/Controller.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/nixd/lib/Server/Controller.cpp b/nixd/lib/Server/Controller.cpp index 675f2009d..4ae311701 100644 --- a/nixd/lib/Server/Controller.cpp +++ b/nixd/lib/Server/Controller.cpp @@ -785,7 +785,9 @@ void Controller::onFormat( TextEdit E{{{0, 0}, {INT_MAX, INT_MAX}}, FormattedCode.value()}; Reply(std::vector{E}); } else { - Reply(lspserver::error("no formatting response received")); + // Suppress the warning, do not pop up + // Reply(lspserver::error("no formatting response received")); + Reply(std::vector{}); } }; boost::asio::post(Pool, std::move(Task));