Skip to content

Commit 8a29c07

Browse files
authored
Merge pull request #1113 from quarkiverse/#1108
Properly warn about missing javac -parameters flag
2 parents 6b6ed17 + 123a182 commit 8a29c07

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

core/deployment/src/main/java/io/quarkiverse/langchain4j/deployment/AiServicesProcessor.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1362,16 +1362,16 @@ private List<TemplateParameterInfo> gatherTemplateParamInfo(List<MethodParameter
13621362
}
13631363
}
13641364

1365-
if ((templateParams.size() == 1) && (params.size() == 1)) {
1366-
// the special 'it' param is supported when the method only has one parameter
1367-
templateParams.add(new TemplateParameterInfo(0, "it"));
1368-
}
1369-
13701365
if (!templateParams.isEmpty() && templateParams.stream().map(TemplateParameterInfo::name).allMatch(Objects::isNull)) {
13711366
log.warn(
13721367
"The application has been compiled without the '-parameters' being set flag on javac. Make sure your build tool is configured to pass this flag to javac, otherwise Quarkus LangChain4j is unlikely to work properly without it.");
13731368
}
13741369

1370+
if ((templateParams.size() == 1) && (params.size() == 1)) {
1371+
// the special 'it' param is supported when the method only has one parameter
1372+
templateParams.add(new TemplateParameterInfo(0, "it"));
1373+
}
1374+
13751375
return templateParams;
13761376
}
13771377

0 commit comments

Comments
 (0)