Simplify if statements
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/csv/trunk@1512399 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
a223126567
commit
1756e67623
|
@ -40,10 +40,7 @@ final class TokenMatchers {
|
|||
final Description mismatchDescription) {
|
||||
mismatchDescription.appendText("token type is ");
|
||||
mismatchDescription.appendValue(item.type);
|
||||
if (item.type == expectedType) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
return item.type == expectedType;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
@ -61,10 +58,7 @@ final class TokenMatchers {
|
|||
final Description mismatchDescription) {
|
||||
mismatchDescription.appendText("token content is ");
|
||||
mismatchDescription.appendValue(item.content.toString());
|
||||
if (expectedContent.equals(item.content.toString())) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
return expectedContent.equals(item.content.toString());
|
||||
}
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue