From 9e0bc0bbc94651c040250559a99f210c36c8694a Mon Sep 17 00:00:00 2001 From: Xiao Qi Date: Mon, 14 Nov 2022 02:52:13 +0800 Subject: [PATCH] Added checks for path exist and bin and obj folders when building directory for asset browser --- SHADE_Engine/src/Filesystem/SHFileSystem.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/SHADE_Engine/src/Filesystem/SHFileSystem.cpp b/SHADE_Engine/src/Filesystem/SHFileSystem.cpp index 1062540b..fa5f718e 100644 --- a/SHADE_Engine/src/Filesystem/SHFileSystem.cpp +++ b/SHADE_Engine/src/Filesystem/SHFileSystem.cpp @@ -130,6 +130,14 @@ namespace SHADE } // If item is folder + if (path.stem().string() == "bin" + || path.stem().string() == "obj" + || !std::filesystem::exists(path)) + { + SHLOG_INFO("[FileSystem] Skipped paths in directory building: {}", path.string()); + continue; + } + auto newFolder{ folder->CreateSubFolderHere(path.stem().string()) }; folderStack.push(newFolder); }