Skip to content

Commit 1162882

Browse files
committed
Removed redundant if statement
1 parent b3d4089 commit 1162882

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

logstash-core/src/main/java/org/logstash/common/BufferedTokenizer.java

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -91,11 +91,7 @@ public synchronized String next() {
9191
* @return true iff a next complete token is available.
9292
*/
9393
private boolean matchNextSeparatorIdx() {
94-
if (nextSeparatorIdx == -1) {
95-
nextSeparatorIdx = accumulator.indexOf(separator, currentIdx);
96-
} else {
97-
nextSeparatorIdx = accumulator.indexOf(separator, currentIdx);
98-
}
94+
nextSeparatorIdx = accumulator.indexOf(separator, currentIdx);
9995

10096
// clean up accumulator if no next separator found
10197
if (nextSeparatorIdx == -1 && currentIdx > 0) {

0 commit comments

Comments
 (0)