1
0
mirror of synced 2024-11-25 00:00:27 +01:00

fix: Don't load constants files that start with a _

This commit is contained in:
WerWolv 2023-06-23 21:39:39 +02:00
parent 1b028dfc0a
commit a7ecefb5a0

View File

@ -30,6 +30,9 @@ namespace hex::plugin::builtin {
for (auto &file : std::fs::directory_iterator(path, error)) {
if (!file.is_regular_file()) continue;
if (file.path().extension() != ".json") continue;
if (file.path().filename().u8string().starts_with('_')) continue;
try {
auto fileData = wolv::io::File(file.path(), wolv::io::File::Mode::Read).readString();
auto content = nlohmann::json::parse(fileData);