Issue with app.fileManager.processFrontMatter

I noticed and issue while using app.fileManager.processFrontMatter.
If this API is used to delete properties from frontmatter and frontmatter ends without keys in result - changes are not saved.
Sample file for testing

---
Something: value
---
Content

Codes used for modification

await app.fileManager.processFrontMatter(file, (fm) => {
   delete fm.Something;
});

After executing this code Something property is still present.
If I add any other property - it gets correctly removed.

await app.fileManager.processFrontMatter(file, (fm) => {
   delete fm.Something;
   fm.foo = "bar"
});
1 Like

Will be fixed 1.5.13

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.