Skip to content

Commit

Permalink
Merge pull request #286 from spyrkob/WFGP-276
Browse files Browse the repository at this point in the history
[WFGP-276] Check if the artifact is a ZIP or a JAR archive before extracting schemas
  • Loading branch information
jfdenise authored Mar 25, 2024
2 parents 49c16cd + 9d71dc2 commit f590045
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1089,7 +1089,9 @@ public void copyArtifact(CopyArtifact copyArtifact, PackageRuntime pkg) throws P
}
IoUtils.copy(jarSrc, jarTarget);
}
if(schemaGroups.contains(artifact.getGroupId())) {
// only attempt to extract schemas if the artifact is a zip archive
if(schemaGroups.contains(artifact.getGroupId())
&& (artifact.getExtension().equals("jar") || artifact.getExtension().equals("zip"))) {
extractSchemas(jarSrc);
}
} catch (IOException e) {
Expand Down

0 comments on commit f590045

Please sign in to comment.