String arrays are only send by servers/Bungeecord. No need to limit their size

This commit is contained in:
Thinkofname 2016-03-29 19:41:16 +01:00
parent 540e924bfb
commit 891ad8711d

View File

@ -56,7 +56,6 @@ public abstract class DefinedPacket
public static void writeStringArray(List<String> s, ByteBuf buf)
{
Preconditions.checkArgument( s.size() <= 64, "Cannot send string array longer than 64 (got %s strings)", s.size() );
writeVarInt( s.size(), buf );
for ( String str : s )
{
@ -67,7 +66,6 @@ public abstract class DefinedPacket
public static List<String> readStringArray(ByteBuf buf)
{
int len = readVarInt( buf );
Preconditions.checkArgument( len <= 64, "Cannot receive string array longer than 64 (got %s strings)", len );
List<String> ret = new ArrayList<>( len );
for ( int i = 0; i < len; i++ )
{