Skip to content

Commit

Permalink
fix: fix getModByHandle when loading mods
Browse files Browse the repository at this point in the history
  • Loading branch information
OEOTYAN committed Dec 31, 2024
1 parent 7d8a138 commit 6667d3e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/ll/core/mod/NativeModManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,12 @@ static std::shared_ptr<NativeMod> currentLoadingMod;

std::shared_ptr<NativeMod> NativeModManager::getModByHandle(Handle handle) {
auto l(lock());
if (currentLoadingMod) { // for getCurrent before main
return currentLoadingMod;
}
if (handleMap.contains(handle)) {
return handleMap.at(handle);
}
if (currentLoadingMod) { // for getCurrent before main
return currentLoadingMod;
}
return {};
}
static void
Expand Down

0 comments on commit 6667d3e

Please sign in to comment.