3
0
Mirror von https://github.com/Moulberry/AxiomPaperPlugin.git synchronisiert 2024-11-09 01:50:05 +01:00

PlotSquared: Change isPlotWorld logic to check for non-zero PlotArea count

Dieser Commit ist enthalten in:
Moulberry 2023-11-17 00:18:28 +08:00
Ursprung 0c05b3a46f
Commit c027e56fc4

Datei anzeigen

@ -128,16 +128,9 @@ public class PlotSquaredIntegrationImpl {
return plotWorldCache.get(world); return plotWorldCache.get(world);
} }
boolean isPlotWorld = false;
String worldName = world.getName(); String worldName = world.getName();
for (String plotWorld : PlotSquared.get().getPlotAreaManager().getAllWorlds()) { PlotArea[] plotAreas = PlotSquared.get().getPlotAreaManager().getPlotAreas(worldName, null);
if (plotWorld.equals(worldName)) { boolean isPlotWorld = plotAreas.length > 0;
isPlotWorld = true;
break;
}
}
plotWorldCache.put(world, isPlotWorld); plotWorldCache.put(world, isPlotWorld);
return isPlotWorld; return isPlotWorld;
} }