diff --git a/source/net/filebot/media/MediaDetection.java b/source/net/filebot/media/MediaDetection.java index 039f79aa..0c4d4ef6 100644 --- a/source/net/filebot/media/MediaDetection.java +++ b/source/net/filebot/media/MediaDetection.java @@ -947,7 +947,7 @@ public class MediaDetection { querySet = getUniqueQuerySet(stripBlacklistedTerms(querySet)); // DEBUG - System.out.format("Query %s: %s%n", queryLookupService.getName(), querySet); + // System.out.format("Query %s: %s%n", queryLookupService.getName(), querySet); final Map probabilityMap = new LinkedHashMap(); final SimilarityMetric metric = getMovieMatchMetric(); diff --git a/source/net/filebot/util/StringUtilities.java b/source/net/filebot/util/StringUtilities.java index b967a913..4fb4a13b 100644 --- a/source/net/filebot/util/StringUtilities.java +++ b/source/net/filebot/util/StringUtilities.java @@ -27,10 +27,9 @@ public final class StringUtilities { public static String join(Iterable values, CharSequence delimiter, CharSequence start, CharSequence end) { StringBuilder sb = new StringBuilder().append(start); - for (Iterator iterator = values.iterator(); iterator.hasNext();) { - Object value = iterator.next(); + for (Object value : values) { if (!isEmpty(value)) { - if (sb.length() > 0) { + if (sb.length() > start.length()) { sb.append(delimiter); } sb.append(value);