Performance improvement as suggested by md_5, thanks.

This commit is contained in:
Olof Larsson 2013-08-21 10:02:40 +02:00
parent a71b3a19f3
commit c5be1754c4

View File

@ -63,7 +63,7 @@ public class FactionsListenerChat implements Listener
{
try
{
if (!AsyncPlayerChatEvent.class.isAssignableFrom(event.getClass())) return;
if (!(event instanceof AsyncPlayerChatEvent)) return;
setFormat((AsyncPlayerChatEvent)event);
}
catch (Throwable t)
@ -89,7 +89,7 @@ public class FactionsListenerChat implements Listener
{
try
{
if (!AsyncPlayerChatEvent.class.isAssignableFrom(event.getClass())) return;
if (!(event instanceof AsyncPlayerChatEvent)) return;
parseTags((AsyncPlayerChatEvent)event);
}
catch (Throwable t)
@ -117,7 +117,7 @@ public class FactionsListenerChat implements Listener
{
try
{
if (!AsyncPlayerChatEvent.class.isAssignableFrom(event.getClass())) return;
if (!(event instanceof AsyncPlayerChatEvent)) return;
parseRelcolor((AsyncPlayerChatEvent)event);
}
catch (Throwable t)