Skip to content

Commit

Permalink
added check if username is null
Browse files Browse the repository at this point in the history
  • Loading branch information
sanchitgarg1909 authored and sayem committed Jul 28, 2020
1 parent da01ce9 commit 569a760
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,8 @@ public void call(Object... args) {
@Override
public void run() {
if(!isConnected) {
mSocket.emit("add user", mUsername);
if(null!=mUsername)
mSocket.emit("add user", mUsername);
Toast.makeText(getActivity().getApplicationContext(),
R.string.connect, Toast.LENGTH_LONG).show();
isConnected = true;
Expand Down

0 comments on commit 569a760

Please sign in to comment.