diff --git a/lib/rust-project.js b/lib/rust-project.js index fc3dce5..bb2c873 100644 --- a/lib/rust-project.js +++ b/lib/rust-project.js @@ -1,6 +1,5 @@ const path = require("path") const fs = require("fs") -const toml = require("toml") const _ = require("underscore-plus") /** @@ -87,39 +86,6 @@ class RustProject { busyMessage.lastProgressTitle = title } } - - // Send rls.toml as `workspace/didChangeConfiguration` message (or default if no rls.toml) - sendRlsTomlConfig() { - const rlsTomlPath = path.join(this.server.projectPath, "rls.toml") - - fs.readFile(rlsTomlPath, (err, data) => { - const config = this.defaultConfig() - if (!err) { - try { - Object.assign(config, toml.parse(data)) - } catch (e) { - console.warn(`Failed to read ${rlsTomlPath}`, e) - } - } - - if (_.isEqual(config, this._lastSentConfig)) { - return - } - - this.server.connection.didChangeConfiguration({ - settings: { - rust: config, - }, - }) - this._lastSentConfig = config - }) - } - - // Default Rls config according to package settings & Rls defaults - /* eslint-disable-next-line class-methods-use-this */ - defaultConfig() { - return {} - } } /**