Skip to content

Commit

Permalink
fix: storage path should use OS dependent fsPath
Browse files Browse the repository at this point in the history
  • Loading branch information
carsakiller authored and sumneko committed Oct 30, 2024
1 parent e5244e6 commit 2c861f3
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions client/src/languageserver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ class LuaClient extends Disposable {
codeLensViewReferences: true,
fixIndents: true,
languageConfiguration: true,
storagePath: this.context.globalStorageUri.path,
storagePath: this.context.globalStorageUri.fsPath,
},
};

Expand Down Expand Up @@ -330,23 +330,23 @@ class LuaClient extends Disposable {
if (typeof config !== 'object' || config === null) {
return config;
}

for (const key in config) {
if (config.hasOwnProperty(key)) {
const value = config[key];

if (typeof value === 'object' && value !== null) {
convertStringsToRegex(value);
}

if (key === 'beforeText' || key === 'afterText') {
if (typeof value === 'string') {
config[key] = new RegExp(value);
}
}
}
}

return config;
}

Expand Down

0 comments on commit 2c861f3

Please sign in to comment.