ruanwenjun commented on code in PR #10689:
URL: https://github.com/apache/dolphinscheduler/pull/10689#discussion_r965522248
##########
dolphinscheduler-task-plugin/dolphinscheduler-task-java/src/main/java/org/apache/dolphinscheduler/plugin/task/java/JavaParameters.java:
##########
@@ -68,7 +69,7 @@ public class JavaParameters extends AbstractParameters {
*/
@Override
public boolean checkParameters() {
- return runType != null && (rawScript != null && !rawScript.isEmpty())
|| mainJar != null;
+ return runType != null && StringUtils.isNotBlank(rawScript) || mainJar
!= null;
Review Comment:
```suggestion
return runType != null && (StringUtils.isNotBlank(rawScript) ||
mainJar != null);
```
When the runType is jar you need to check if the `mainJar != null`, when the
runType is script you need to check if the `rawScript != null`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]