simplify_if (#543)
This commit is contained in:
parent
a9be3ec55b
commit
fb2d228380
|
@ -439,7 +439,7 @@ public abstract class ToStringStyle implements Serializable {
|
|||
protected void removeLastFieldSeparator(final StringBuffer buffer) {
|
||||
final int len = buffer.length();
|
||||
final int sepLen = fieldSeparator.length();
|
||||
if (len > 0 && sepLen > 0 && len >= sepLen) {
|
||||
if (sepLen > 0 && len >= sepLen) {
|
||||
boolean match = true;
|
||||
for (int i = 0; i < sepLen; i++) {
|
||||
if (buffer.charAt(len - 1 - i) != fieldSeparator.charAt(sepLen - 1 - i)) {
|
||||
|
|
|
@ -76,7 +76,7 @@ public class StringUtilsEqualsIndexOfTest {
|
|||
|
||||
@Override
|
||||
public boolean equals(final Object obj) {
|
||||
if (obj == null || !(obj instanceof CustomCharSequence)) {
|
||||
if (!(obj instanceof CustomCharSequence)) {
|
||||
return false;
|
||||
}
|
||||
final CustomCharSequence other = (CustomCharSequence) obj;
|
||||
|
|
Loading…
Reference in New Issue