From 00567dea68f1daecffa25d43b9e237e0a3d8452a Mon Sep 17 00:00:00 2001 From: Blaine Lewis Date: Thu, 8 Feb 2024 10:25:22 -0500 Subject: [PATCH] fix bug where files have same name but differing paths --- src/main.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.ts b/src/main.ts index 6ae7ac6..dc2b449 100644 --- a/src/main.ts +++ b/src/main.ts @@ -174,7 +174,7 @@ export default class FileDiffPlugin extends Plugin { '' ); const originalFile = files.find( - (f) => f.name === originalFileName + (f) => f.name === originalFileName && (file.parent?.path ?? "") === (f.parent?.path ?? "") ); if (originalFile) {