From 612402d9cb9fc892652f0b0f4d964e02c1a21eda Mon Sep 17 00:00:00 2001 From: SirYwell Date: Wed, 21 Dec 2022 16:11:58 +0100 Subject: [PATCH] Avoid extensive hashing of plots --- .../com/plotsquared/core/util/query/GlobalPlotProvider.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/util/query/GlobalPlotProvider.java b/Core/src/main/java/com/plotsquared/core/util/query/GlobalPlotProvider.java index 2e635101e..e02994e63 100644 --- a/Core/src/main/java/com/plotsquared/core/util/query/GlobalPlotProvider.java +++ b/Core/src/main/java/com/plotsquared/core/util/query/GlobalPlotProvider.java @@ -23,9 +23,9 @@ import com.plotsquared.core.plot.PlotArea; import com.plotsquared.core.plot.world.PlotAreaManager; import org.checkerframework.checker.nullness.qual.NonNull; +import java.util.ArrayList; import java.util.Collection; -import java.util.HashSet; -import java.util.Set; +import java.util.List; class GlobalPlotProvider implements PlotProvider { @@ -37,7 +37,7 @@ class GlobalPlotProvider implements PlotProvider { @Override public Collection getPlots() { - final Set plots = new HashSet<>(); + final List plots = new ArrayList<>(); for (final PlotArea plotArea : this.plotAreaManager.getAllPlotAreas()) { plots.addAll(plotArea.getPlots()); }