Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix max build variable dependencies #1278

Merged
merged 1 commit into from
Nov 23, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions core/src/main/java/tc/oc/pgm/api/module/ModuleGraph.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

import java.util.Collection;
import java.util.Collections;
import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.Stack;
import java.util.concurrent.atomic.AtomicBoolean;
Expand Down Expand Up @@ -60,7 +60,7 @@ protected void loadAll() throws ModuleLoadException {

protected void unloadAll() {
if (loaded.compareAndSet(true, false)) {
modules = new HashMap<>(factories.size());
modules = new LinkedHashMap<>(factories.size());
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
import tc.oc.pgm.api.module.exception.ModuleLoadException;
import tc.oc.pgm.blitz.BlitzMatchModule;
import tc.oc.pgm.filters.Filterable;
import tc.oc.pgm.regions.RegionMatchModule;
import tc.oc.pgm.score.ScoreMatchModule;
import tc.oc.pgm.teams.TeamMatchModule;
import tc.oc.pgm.util.math.Formula;
Expand All @@ -50,7 +51,11 @@ public VariablesModule(ImmutableList<VariableDefinition<?>> variables) {

@Override
public @Nullable Collection<Class<? extends MatchModule>> getWeakDependencies() {
return ImmutableList.of(TeamMatchModule.class, BlitzMatchModule.class, ScoreMatchModule.class);
return ImmutableList.of(
TeamMatchModule.class,
BlitzMatchModule.class,
ScoreMatchModule.class,
RegionMatchModule.class);
}

@SuppressWarnings("unchecked")
Expand Down