#827 - Fix team settings file recreation

This commit is contained in:
Elio Struyf
2024-06-27 21:35:20 +02:00
parent bd1fc32f1c
commit 0e6e776f70
2 changed files with 5 additions and 1 deletions

View File

@@ -13,6 +13,8 @@
### 🐞 Fixes
- [#827](https://github.com/estruyf/vscode-front-matter/issues/827): Fix for `frontmatter.json` file which gets created when already present in a sub-folder
## [10.2.0] - 2024-06-12 - [Release notes](https://beta.frontmatter.codes/updates/v10.2.0)
### ✨ New features

View File

@@ -516,7 +516,9 @@ ${JSON.stringify(value, null, 2)}`,
}frontmatter.codes/frontmatter.schema.json`
};
if (wsFolder) {
const projectFile = await Settings.projectConfigPath();
if (wsFolder && !projectFile) {
const configPath = join(wsFolder.fsPath, Settings.globalFile);
if (!(await existsAsync(configPath))) {
await writeFileAsync(configPath, JSON.stringify(initialConfig, null, 2), 'utf8');