Skip to content

Commit 1a7cb8a

Browse files
authored
Use concurrent maps in MIHookTracker to (hopefully) avoid concurrency issues (#158)
1 parent 534fc1d commit 1a7cb8a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/main/java/net/swedz/tesseract/neoforge/compat/mi/hook/MIHookTracker.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@
1616
@ApiStatus.Internal
1717
public final class MIHookTracker
1818
{
19-
private static final Map<ResourceLocation, String> REI_CATEGORY_NAMES = Maps.newHashMap();
20-
private static final Map<ResourceLocation, MachineModelProperties> MACHINE_MODELS = Maps.newHashMap();
21-
private static final Map<String, List<Consumer<MachineCasingModelsMIHookDatagenProvider>>> MACHINE_CASING_MODELS = Maps.newHashMap();
19+
private static final Map<ResourceLocation, String> REI_CATEGORY_NAMES = Maps.newConcurrentMap();
20+
private static final Map<ResourceLocation, MachineModelProperties> MACHINE_MODELS = Maps.newConcurrentMap();
21+
private static final Map<String, List<Consumer<MachineCasingModelsMIHookDatagenProvider>>> MACHINE_CASING_MODELS = Maps.newConcurrentMap();
2222

2323
public static List<Map.Entry<ResourceLocation, String>> getReiCategoryNames(String modId)
2424
{

0 commit comments

Comments
 (0)