File tree 1 file changed +14
-2
lines changed
org.springframework.context/src/main/java/org/springframework/conversation/manager
1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change @@ -361,8 +361,20 @@ public boolean isNested() {
361
361
* @see org.springframework.conversation.manager.MutableConversation#isParent()
362
362
*/
363
363
public boolean isParent () {
364
- return (children != null && children .size () > 0 );
365
- }
364
+ if (children == null || children .size () == 0 ) {
365
+ return false ;
366
+ }
367
+
368
+ // step through the list of children and search for at least one active child conversation in order to
369
+ // make this an active parent
370
+ for (MutableConversation conversation : children ) {
371
+ if (!conversation .isEnded ()) {
372
+ return true ;
373
+ }
374
+ }
375
+
376
+ return false ;
377
+ }
366
378
367
379
/**
368
380
* @see org.springframework.conversation.Conversation#isTemporary()
You can’t perform that action at this time.
0 commit comments