This is an automated email from the ASF dual-hosted git repository.

zehnder pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/streampipes.git


The following commit(s) were added to refs/heads/dev by this push:
     new f9eb0cc31a Fix CheckCompletedVisitor outOfBounds (#2714)
f9eb0cc31a is described below

commit f9eb0cc31aa553d2d0a7f53532866302c10b2b19
Author: yanfeng1992 <[email protected]>
AuthorDate: Mon Apr 8 20:09:52 2024 +0800

    Fix CheckCompletedVisitor outOfBounds (#2714)
    
    Signed-off-by: huangyanfeng <[email protected]>
---
 .../manager/matching/v2/pipeline/CheckCompletedVisitor.java         | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git 
a/streampipes-pipeline-management/src/main/java/org/apache/streampipes/manager/matching/v2/pipeline/CheckCompletedVisitor.java
 
b/streampipes-pipeline-management/src/main/java/org/apache/streampipes/manager/matching/v2/pipeline/CheckCompletedVisitor.java
index 2df44aecb5..11fe5f9b54 100644
--- 
a/streampipes-pipeline-management/src/main/java/org/apache/streampipes/manager/matching/v2/pipeline/CheckCompletedVisitor.java
+++ 
b/streampipes-pipeline-management/src/main/java/org/apache/streampipes/manager/matching/v2/pipeline/CheckCompletedVisitor.java
@@ -117,8 +117,10 @@ public class CheckCompletedVisitor extends 
DefaultStaticPropertyVisitor {
         }
       }
     } else {
-      String firstSelector = mappingPropertyUnary.getMapsFromOptions().get(0);
-      mappingPropertyUnary.setSelectedProperty(firstSelector);
+      if (!mappingPropertyUnary.getMapsFromOptions().isEmpty()){
+        String firstSelector = 
mappingPropertyUnary.getMapsFromOptions().get(0);
+        mappingPropertyUnary.setSelectedProperty(firstSelector);
+      }
     }
   }
 

Reply via email to