fix: Cleanup output channels when restarting server

This commit is contained in:
Lukas Wirth 2022-06-05 13:24:39 +02:00
parent d38b7b88c6
commit fd298b3994

View file

@ -43,6 +43,8 @@ export class Ctx {
const res = new Ctx(config, extCtx, client, serverPath, statusBar); const res = new Ctx(config, extCtx, client, serverPath, statusBar);
res.pushCleanup(client.start()); res.pushCleanup(client.start());
res.pushCleanup(client.traceOutputChannel);
res.pushCleanup(client.outputChannel);
await client.onReady(); await client.onReady();
client.onNotification(ra.serverStatus, (params) => res.setServerStatus(params)); client.onNotification(ra.serverStatus, (params) => res.setServerStatus(params));
return res; return res;