Skip to content

Commit

Permalink
could have encountered multithreading issues? not sure
Browse files Browse the repository at this point in the history
  • Loading branch information
Matt-MX committed Feb 15, 2024
1 parent 3d37a75 commit c99f2aa
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion api/src/main/kotlin/com/mattmx/ktgui/GuiManager.kt
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,14 @@ import org.bukkit.event.player.PlayerQuitEvent
import org.bukkit.event.server.PluginDisableEvent
import org.bukkit.plugin.java.JavaPlugin
import org.jetbrains.annotations.ApiStatus
import java.util.Collections

/**
* Handles all GUI click events, as well
* as events we might need to know while in a GUI.
*/
object GuiManager : Listener {
private val players = hashMapOf<Player, IGuiScreen>()
private val players = Collections.synchronizedMap(hashMapOf<Player, IGuiScreen>())
private var initialized = false
private val defaultConfiguration = Configuration()
private val configurations = hashMapOf<JavaPlugin, Configuration>()
Expand Down

0 comments on commit c99f2aa

Please sign in to comment.