Plugin randomly nulls and breaks on /mm reload
Summary
Plugin randomly nulls and breaks on /mm reload
Steps to reproduce
Keep doing /mm r until it breaks
Server log file
[16:48:49 INFO]: SlyJacob_ issued server command: /mm r
[16:48:49 ERROR]: null
org.bukkit.command.CommandException: Unhandled exception executing command 'mm' in plugin MythicMobs v5.0.0-SNAPSHOT-f198d3af
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:47) ~[patched_1.17.1.jar:git-Paper-116]
at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:159) ~[patched_1.17.1.jar:git-Paper-116]
at org.bukkit.craftbukkit.v1_17_R1.CraftServer.dispatchCommand(CraftServer.java:821) ~[patched_1.17.1.jar:git-Paper-116]
at net.minecraft.server.network.ServerGamePacketListenerImpl.handleCommand(ServerGamePacketListenerImpl.java:2170) ~[?:?]
at net.minecraft.server.network.ServerGamePacketListenerImpl.handleChat(ServerGamePacketListenerImpl.java:1981) ~[?:?]
at net.minecraft.server.network.ServerGamePacketListenerImpl.handleChat(ServerGamePacketListenerImpl.java:1962) ~[?:?]
at net.minecraft.network.protocol.game.ServerboundChatPacket.handle(ServerboundChatPacket.java:46) ~[?:?]
at net.minecraft.network.protocol.game.ServerboundChatPacket.handle(ServerboundChatPacket.java:6) ~[?:?]
at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$1(PacketUtils.java:36) ~[?:?]
at net.minecraft.server.TickTask.run(TickTask.java:18) ~[patched_1.17.1.jar:git-Paper-116]
at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:149) ~[?:?]
at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:23) ~[?:?]
at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:1348) ~[patched_1.17.1.jar:git-Paper-116]
at net.minecraft.server.MinecraftServer.shouldRun(MinecraftServer.java:190) ~[patched_1.17.1.jar:git-Paper-116]
at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:122) ~[?:?]
at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:1327) ~[patched_1.17.1.jar:git-Paper-116]
at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:1320) ~[patched_1.17.1.jar:git-Paper-116]
at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:132) ~[?:?]
at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1397) ~[patched_1.17.1.jar:git-Paper-116]
at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1188) ~[patched_1.17.1.jar:git-Paper-116]
at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:316) ~[patched_1.17.1.jar:git-Paper-116]
at java.lang.Thread.run(Thread.java:831) [?:?]
Caused by: java.util.ConcurrentModificationException
at java.util.ArrayList.removeIf(ArrayList.java:1685) ~[?:?]
at java.util.ArrayList.removeIf(ArrayList.java:1660) ~[?:?]
at io.lumine.xikage.mythicmobs.spawning.spawners.MythicSpawner.unloadSpawner(MythicSpawner.java:250) ~[?:?]
at io.lumine.xikage.mythicmobs.spawning.spawners.SpawnerManager.resetAndSaveAll(SpawnerManager.java:231) ~[?:?]
at io.lumine.xikage.mythicmobs.commands.ReloadCommand.onCommand(ReloadCommand.java:26) ~[?:?]
at io.lumine.xikage.mythicmobs.utils.commands.Command.onCommand(Command.java:64) ~[?:?]
at io.lumine.xikage.mythicmobs.utils.commands.Command.onCommand(Command.java:61) ~[?:?]
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:45) ~[patched_1.17.1.jar:git-Paper-116]
... 21 more
Paper git-paper-116 1.17.1 MythicMobs 5.0.0-snap-f198d3af
Edit: Just tried it again at Paper-130, MythicMobs 5.0.0-Snapshot-0bd33ed9 and still occurs randomly when reloading the plugin with /mm r