When I grab the IP Address from my open socket, as someone has sent me a stream, I noticed that the IP has a forward-slash.
I just plan to simply omit it. But first I want to validate the first character in the string is the forward-slash:
String dataSource = data.getAddress().toString();
if(dataSource.substring(0,1) == "/"){
System.out.println("trailing forward slash, delete it ");
dataSource = dataSource.substring(1);
}
This IF statement isn't being detected.
Anyone see what I'm doing wrong?