Why my code is wrong for "a","", but it works in eclipse??

```
public boolean isOneEditDistance(String s, String t) {
int len_s = s.length();
int len_t = t.length();
if(Math.abs(len_s - len_t) > 1||s.equals(t)) return false;
int count = 0;
if(len_s == len_t){
for(int i = 0; i < len_s; i++){
if(count > 1) return false;
if(s.charAt(i) != t.charAt(i) ) count++;
}
}
else{
if(s == "" || t == "") return true;
int len = Math.min(len_s,len_t);
for(int i = 0,j=0; i < len && j < len; i++,j++){
if(count > 1) return false;
if(s.charAt(i) != t.charAt(j)){
count++;
if(len_s < len_t) i--;
else j--;
}
}
}
return count == 1;
```

}