Merge pull request #36 from Scarsz/patch-1

Fix NoSuchMethodError with DiscordSRV hook
This commit is contained in:
Chris 2018-03-13 20:17:02 -07:00 committed by GitHub
commit c97a0dce4e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -44,7 +44,7 @@ public class DiscordListener {
@Subscribe(priority = ListenerPriority.MONITOR) @Subscribe(priority = ListenerPriority.MONITOR)
public void onDiscordGuildMessageReceivedEvent(DiscordGuildMessageReceivedEvent event) { public void onDiscordGuildMessageReceivedEvent(DiscordGuildMessageReceivedEvent event) {
if (discordPlugin.getConfig().getBoolean("DiscordChatChannelListCommandEnabled") if (discordPlugin.getConfig().getBoolean("DiscordChatChannelListCommandEnabled")
&& event.getMessage().getContent().equalsIgnoreCase(discordPlugin.getConfig().getString("DiscordChatChannelListCommandMessage"))) { && event.getMessage().getContentRaw().equalsIgnoreCase(discordPlugin.getConfig().getString("DiscordChatChannelListCommandMessage"))) {
plugin.logDebug("[onDiscordGuildMessageReceivedEvent] Ignoring DiscordChatChannelListCommandMessage"); plugin.logDebug("[onDiscordGuildMessageReceivedEvent] Ignoring DiscordChatChannelListCommandMessage");
return; return;
} }
@ -54,7 +54,7 @@ public class DiscordListener {
event.getMember().getEffectiveName(), event.getMember().getEffectiveName(),
event.getMember().getColor(), event.getMember().getColor(),
event.getChannel().getName(), event.getChannel().getName(),
event.getMessage().getContent()); event.getMessage().getContentDisplay());
} }
} }