#3207: Rework the plugin message relaying system to allow unregistering channels
This commit is contained in:
@@ -2,7 +2,6 @@ package net.md_5.bungee.protocol.packet;
|
||||
|
||||
import com.google.common.base.Function;
|
||||
import com.google.common.base.Preconditions;
|
||||
import com.google.common.base.Predicate;
|
||||
import io.netty.buffer.ByteBuf;
|
||||
import java.io.ByteArrayInputStream;
|
||||
import java.io.DataInput;
|
||||
@@ -48,14 +47,6 @@ public class PluginMessage extends DefinedPacket
|
||||
return "legacy:" + tag.toLowerCase( Locale.ROOT );
|
||||
}
|
||||
};
|
||||
public static final Predicate<PluginMessage> SHOULD_RELAY = new Predicate<PluginMessage>()
|
||||
{
|
||||
@Override
|
||||
public boolean apply(PluginMessage input)
|
||||
{
|
||||
return ( input.getTag().equals( "REGISTER" ) || input.getTag().equals( "minecraft:register" ) || input.getTag().equals( "MC|Brand" ) || input.getTag().equals( "minecraft:brand" ) ) && input.getData().length < Byte.MAX_VALUE;
|
||||
}
|
||||
};
|
||||
//
|
||||
private String tag;
|
||||
private byte[] data;
|
||||
|
Reference in New Issue
Block a user