Skip to content

Commit

Permalink
Merge 90cca03 into 3b702a4
Browse files Browse the repository at this point in the history
  • Loading branch information
koebbingd committed Jul 27, 2018
2 parents 3b702a4 + 90cca03 commit 3d3f7bb
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,12 @@ private FormatterChain(final List<Formatter> formatter, final int index) {
* Gets the next formatter in the chain.
* @return The formatter at the next index.
*/
private FormatterChain next() {
return new FormatterChain(chain, index + 1);
private Formatter.Chain next() {
if (index < chain.size()) {
return new FormatterChain(chain, index + 1);
} else {
return Formatter.NOOP;
}
}

@Override
Expand Down

0 comments on commit 3d3f7bb

Please sign in to comment.