update liteflow-core/src/main/java/com/yomahub/liteflow/flow/element/condition/SwitchCondition.java.

SwitchCondition节点若在流程中未设置id,会导致 executable.getId() 为null,从而报NPE异常

Signed-off-by: zcl <9928619+zhangcl1991@user.noreply.gitee.com>
This commit is contained in:
zcl 2023-08-03 04:58:18 +00:00 committed by Gitee
parent 938afb6ad6
commit 09f3412289
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 1 additions and 1 deletions

View File

@ -64,7 +64,7 @@ public class SwitchCondition extends Condition {
}
else {
targetExecutor = targetList.stream()
.filter(executable -> executable.getId().equals(targetId))
.filter(executable -> ObjectUtil.equal(executable.getId(),targetId) )
.findFirst()
.orElse(null);
}