Answers for ""continue" in cursor.forEach()"

0

"continue" in cursor.forEach()

elementsCollection.forEach(function(element){
  if (!element.shouldBeProcessed)
    return; // stop processing this iteration

  // This part will be avoided if not neccessary
  doSomeLengthyOperation();
});
Posted by: Guest on March-13-2022

Code answers related to ""continue" in cursor.forEach()"

Browse Popular Code Answers by Language