Update ChatFragment.java
This will avoid exceeding the message length limit if player send a message with spaces in end/start message
This commit is contained in:
@@ -168,10 +168,10 @@ public class ChatFragment extends Table{
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void sendMessage(){
|
private void sendMessage(){
|
||||||
String message = chatfield.getText();
|
String message = chatfield.getText().trim();
|
||||||
clearChatInput();
|
clearChatInput();
|
||||||
|
|
||||||
if(message.replace(" ", "").isEmpty()) return;
|
if(message.isEmpty()) return;
|
||||||
|
|
||||||
history.insert(1, message);
|
history.insert(1, message);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user