mirror of
https://github.com/MilkBowl/Vault.git
synced 2024-11-10 21:01:03 +01:00
mchatSuite listeners still using old mChat info.
This commit is contained in:
parent
67b2af2ed5
commit
23330bfd33
@ -49,7 +49,7 @@ public class Chat_mChatSuite extends Chat {
|
||||
// Load Plugin in case it was loaded before
|
||||
if (mChat == null) {
|
||||
Plugin chat = plugin.getServer().getPluginManager().getPlugin("mChatSuite");
|
||||
if (chat != null) {
|
||||
if (chat != null && chat.isEnabled()) {
|
||||
mChat = (mChatSuite) chat;
|
||||
mReader = mChat.getReader();
|
||||
mWriter = mChat.getWriter();
|
||||
@ -68,12 +68,12 @@ public class Chat_mChatSuite extends Chat {
|
||||
@EventHandler(priority = EventPriority.MONITOR)
|
||||
public void onPluginEnable(PluginEnableEvent event) {
|
||||
if (this.chat.mChat == null) {
|
||||
Plugin chat = plugin.getServer().getPluginManager().getPlugin("mChat");
|
||||
Plugin chat = plugin.getServer().getPluginManager().getPlugin("mChatSuite");
|
||||
if (chat != null) {
|
||||
this.chat.mChat = (mChatSuite) chat;
|
||||
mReader = mChat.getReader();
|
||||
mWriter = mChat.getWriter();
|
||||
log.info(String.format("[%s][Chat] %s hooked.", plugin.getDescription().getName(), "mChat"));
|
||||
log.info(String.format("[%s][Chat] %s hooked.", plugin.getDescription().getName(), "mChatSuite"));
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -81,11 +81,11 @@ public class Chat_mChatSuite extends Chat {
|
||||
@EventHandler(priority = EventPriority.MONITOR)
|
||||
public void onPluginDisable(PluginDisableEvent event) {
|
||||
if (this.chat.mChat != null) {
|
||||
if (event.getPlugin().getDescription().getName().equals("mChat")) {
|
||||
if (event.getPlugin().getDescription().getName().equals("mChatSuite")) {
|
||||
this.chat.mChat = null;
|
||||
mReader = null;
|
||||
mWriter = null;
|
||||
log.info(String.format("[%s][Chat] %s un-hooked.", plugin.getDescription().getName(), "mChat"));
|
||||
log.info(String.format("[%s][Chat] %s un-hooked.", plugin.getDescription().getName(), "mChatSuite"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -234,10 +234,6 @@ public class Permission_PermissionsBukkit extends Permission {
|
||||
public String[] getGroups() {
|
||||
List<String> groupNames = new ArrayList<String>();
|
||||
for (Group group : perms.getAllGroups()) {
|
||||
//Ignore groups with bad data.
|
||||
if (group == null || group.getName() == null) {
|
||||
continue;
|
||||
}
|
||||
groupNames.add(group.getName());
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user