Skip to content

Commit

Permalink
fix: Build issues
Browse files Browse the repository at this point in the history
  • Loading branch information
WerWolv committed Jun 7, 2024
1 parent 8531a67 commit d7845ec
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions plugins/script_loader/source/loaders/dotnet/dotnet_loader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -279,8 +279,8 @@ namespace hex::script::loader {
}

void DotNetLoader::clearScripts() {
std::erase_if(getScripts(), [](const Script *script) {
return !script->background;
std::erase_if(getScripts(), [](const Script &script) {
return !script.background;
});
}

Expand Down
4 changes: 2 additions & 2 deletions plugins/script_loader/source/plugin_script_loader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ namespace {
void loadScript(std::vector<const Script*> &scripts, auto &loader) {
loader.loadAll();

for (auto &script : loader.getScripts())
for (auto &script : std::as_const(loader).getScripts())
scripts.emplace_back(&script);
}

Expand Down Expand Up @@ -106,7 +106,7 @@ namespace {
}

for (const auto &script : scripts) {
const auto &[name, background, entryPoint, loader] = *script;
const auto &[name, path, background, entryPoint, loader] = *script;
if (background)
continue;

Expand Down

0 comments on commit d7845ec

Please sign in to comment.