fix(editor): Fix onConfigChange to send the correct config for didChangeConfiguration notification (#6962)

This currently fails because it sends over data that the language server
isn't prepared to deserialize. This updates to send over the correct
`LanguageServerConfig` type.

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
Nicholas Rayburn 2024-10-27 19:38:57 -05:00 committed by GitHub
parent 83d1f69f75
commit ebf37539c0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -175,7 +175,7 @@ export async function activate(context: ExtensionContext) {
});
config.onConfigChange = function onConfigChange() {
let settings: any = JSON.parse(JSON.stringify(this));
let settings = this.toLanguageServerConfig();
updateStatsBar(settings.enable);
client.sendNotification('workspace/didChangeConfiguration', { settings });
};