fix: check old file using active file set in component

This commit is contained in:
Jacobtread 2024-04-15 21:05:37 +12:00
parent 18af825fdd
commit 07e8ba2bb8

View file

@ -111,10 +111,7 @@ class TimekeepComponent extends MarkdownRenderChild {
this.onRenameEvent = this.vault.on(
"rename",
(file: TAbstractFile, oldName: string) => {
if (
file instanceof TFile &&
oldName == this.context.sourcePath
) {
if (file instanceof TFile && oldName == this.fileSourcePath) {
this.fileSourcePath = file.path;
}
}