try (JarFile jarFile = new JarFile(artifactFile)) {
SortedMap<String, JarEntry> matches = gatherMatchingEntries(jarFile,
filter);
if (matches.isEmpty()) {
getLog().warn("No " + name + " file found for " + project.gav());
<BUG>continue;
} else if (matches.size() > 1) {
getLog().warn("Multiple " + name + " files found for " + project.gav() + ": " + matches.keySet()</BUG>
+ "; taking first");
} else {

try (JarFile jarFile = new JarFile(artifactFile)) {
SortedMap<String, JarEntry> matches = gatherMatchingEntries(jarFile,
filter);
if (matches.isEmpty()) {
getLog().warn("No " + name + " file found for " + project.gav());
} else {
if (matches.size() > 1) {
getLog().warn("Multiple " + name + " files found for " + project.gav() + ": " + matches.keySet()
+ "; taking first");
} else {
