Commits

Frank Bennett committed 1310061

Pop output blob object on an is-parallel condition only once per request

  • Participants
  • Parent commits 42e3c66

Comments (0)

Files changed (1)

src/util_parallel.js

 
 CSL.Parallel.prototype.purgeGroupsIfParallel = function (opposite_condition) {
     var condition = !opposite_condition;
-    for (var i = 0, ilen = this.parallel_conditional_blobs_list.length; i < ilen; i += 1) {
+    for (var i = this.parallel_conditional_blobs_list.length - 1; i > -1; i += -1) {
         var obj = this.parallel_conditional_blobs_list[i];
         if (obj.condition === condition) {
             var buffer = [];
             }
             
         }
+        this.parallel_conditional_blobs_list.pop();
     }
 }