Browse Source

outdoor users(7)

Louis Farina 11 months ago
parent
commit
516c0faf00
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      src/chat/NetworkClient.java

+ 2
- 2
src/chat/NetworkClient.java View File

@@ -193,7 +193,7 @@ class ReceiveThread extends Thread {
193 193
 				            	}
194 194
 				            }
195 195
 				            
196
-				            if(!message.isRedirected() && message.getAuthor() != user.getName())
196
+				            if(!message.isRedirected() && !message.getAuthor().equals(user.getName()))
197 197
 				            {
198 198
 				            	socket.close();
199 199
 				            	if(!isOutdoor)
@@ -216,7 +216,7 @@ class ReceiveThread extends Thread {
216 216
 			        	}
217 217
 			            displayArea.setCaretPosition(displayArea.getDocument().getLength());
218 218
 	            	}
219
-	            	if(message.getAuthor() != user.getName())
219
+	            	if(!message.getAuthor().equals(user.getName()) && !message.isRedirected())
220 220
 	            	{
221 221
 	            		for(Socket s:outdoor_dest_sockets)
222 222
 				    	{

Loading…
Cancel
Save