I’d like to report the same issue as reported by @sararkin at Vault.rename(file, path) is not updating existing links - Bug graveyard - Obsidian Forum.
Since the moderator suggest the bug should belongs to API sections. I’d like to report here again.
My system and obsidian version is different from sararkin, but the problem remains.
Steps to reproduce
const view = this.app.workspace.getActiveViewOfType(MarkdownView);
const newPath = "hoge.md";
this.app.vault.rename(view.file, newPath);
Expected result
Renames file and updates all links, same behavior as just renaming manually
Actual result
Renames the file, The vault.on(“rename”) event is indeed triggered. But existing links aren’t updated to point to the new file
Environment
- Operating system: Windows 10
- Obsidian version: v0.13.23
Thanks,
anselmwang