summaryrefslogtreecommitdiffstats
path: root/EssentialsChat
diff options
context:
space:
mode:
authorsnowleo <schneeleo@gmail.com>2012-08-03 21:45:32 +0200
committersnowleo <schneeleo@gmail.com>2012-08-03 21:45:32 +0200
commit5b3993b1908704cccb61b902c5827c898a9ad45a (patch)
tree52969a913a0f7d0f5e6c40240e362b4a075aec8c /EssentialsChat
parent18ec08ad54fca1cc6d6b1ef1a4eacaa6b85f6763 (diff)
downloadEssentials-5b3993b1908704cccb61b902c5827c898a9ad45a.tar
Essentials-5b3993b1908704cccb61b902c5827c898a9ad45a.tar.gz
Essentials-5b3993b1908704cccb61b902c5827c898a9ad45a.tar.lz
Essentials-5b3993b1908704cccb61b902c5827c898a9ad45a.tar.xz
Essentials-5b3993b1908704cccb61b902c5827c898a9ad45a.zip
Synchronized chatStore
Diffstat (limited to 'EssentialsChat')
-rw-r--r--EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java
index 436bb55e5..3148fe0ff 100644
--- a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java
+++ b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java
@@ -2,6 +2,7 @@ package com.earth2me.essentials.chat;
import static com.earth2me.essentials.I18n._;
import com.earth2me.essentials.IEssentials;
+import java.util.Collections;
import java.util.HashMap;
import java.util.Map;
import java.util.concurrent.ConcurrentSkipListMap;
@@ -33,7 +34,7 @@ public class EssentialsChat extends JavaPlugin
}
chatListener = new ConcurrentSkipListMap<String, IEssentialsChatListener>();
- final Map<PlayerChatEvent, ChatStore> chatStore = new HashMap<PlayerChatEvent, ChatStore>();
+ final Map<PlayerChatEvent, ChatStore> chatStore = Collections.synchronizedMap(new HashMap<PlayerChatEvent, ChatStore>());
final EssentialsChatPlayerListenerLowest playerListenerLowest = new EssentialsChatPlayerListenerLowest(getServer(), ess, chatListener, chatStore);