def reply_to_parent(_workitem)
if h.remaining == 'wait'
if workitem_count >= count_list_size
h.workitem = final_merge
do_unpersist && super(h.workitem, false)
elsif h.children_cancelled == nil
h.children_cancelled = true
do_persist
h.children.each { |i| @context.storage.put_msg('cancel', 'fei' => i) }
end
return
end
h.workitem = final_merge
if h.children.empty?
do_unpersist && super(h.workitem, false)
elsif h.remaining == 'cancel'
if do_unpersist
super(h.workitem, false)
h.children.each { |i| @context.storage.put_msg('cancel', 'fei' => i) }
end
else
h.variables = compile_variables
h.forgotten = true
do_persist && super(h.workitem, false)
end
end