From 9ac5ae9cb58a9606e5441c8cb70c120acfd2ed2e Mon Sep 17 00:00:00 2001 From: Bohdan Ohorodnii Date: Wed, 8 Jan 2025 18:42:59 +0200 Subject: [PATCH] hotfix: source path problem --- plugin/src/features/Compilation/index.tsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugin/src/features/Compilation/index.tsx b/plugin/src/features/Compilation/index.tsx index 5923c13..264e232 100644 --- a/plugin/src/features/Compilation/index.tsx +++ b/plugin/src/features/Compilation/index.tsx @@ -290,10 +290,13 @@ const Compilation: React.FC = ({ setAccordian }) => { ): Promise => { const files = [] as FileContentMap[]; const pathFiles = await remixClient.fileManager.readdir(`${workspacePath}/${dirPath}`); + for (const [path, entry] of Object.entries(pathFiles)) { if (entry.isDirectory === true) { - const deps = await getFolderFilemapRecursive(workspacePath, path); + const deps = await getFolderFilemapRecursive(workspacePath, dirPath + "/" + path); + for (const dep of deps) files.push(dep); + continue; } @@ -306,6 +309,7 @@ const Compilation: React.FC = ({ setAccordian }) => { file_content: content }); } + return files; };