This is an automated email from the ASF dual-hosted git repository.
slachiewicz pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-jlink-plugin.git
The following commit(s) were added to refs/heads/master by this push:
new 0445879 Simplify redundant code
0445879 is described below
commit 0445879348753c0b4dc99036a016407b42859c98
Author: Sylwester Lachiewicz <[email protected]>
AuthorDate: Tue Nov 17 06:52:15 2026 +0000
Simplify redundant code
---
src/main/java/org/apache/maven/plugins/jlink/AbstractJLinkMojo.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git
a/src/main/java/org/apache/maven/plugins/jlink/AbstractJLinkMojo.java
b/src/main/java/org/apache/maven/plugins/jlink/AbstractJLinkMojo.java
index f3bfdfb..b722989 100644
--- a/src/main/java/org/apache/maven/plugins/jlink/AbstractJLinkMojo.java
+++ b/src/main/java/org/apache/maven/plugins/jlink/AbstractJLinkMojo.java
@@ -92,7 +92,7 @@ public abstract class AbstractJLinkMojo extends AbstractMojo {
if (jdkToolchain != null) {
List<Toolchain> tcs = toolchainManager.getToolchains(getSession(),
"jdk", jdkToolchain);
- if (tcs != null && tcs.size() > 0) {
+ if (tcs != null && !tcs.isEmpty()) {
tc = tcs.get(0);
}
}