Skip to content

Commit

Permalink
···
Browse files Browse the repository at this point in the history
  • Loading branch information
Hitomis committed May 25, 2017
1 parent 5de566c commit ddadafb
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,9 @@ private void checkConfig() {
if (transConfig.isSourceEmpty())
throw new IllegalArgumentException("the parameter sourceImageList can't be empty");

if (transConfig.getNowThumbnailIndex() >= transConfig.getOriginImageList().size())
throw new IllegalArgumentException("the parameter nowThumbnailIndex will generate an IndexOutOfBoundsException error");

transConfig.setNowThumbnailIndex(transConfig.getNowThumbnailIndex() < 0
? 0 : transConfig.getNowThumbnailIndex());

Expand Down

0 comments on commit ddadafb

Please sign in to comment.