JS: When looping over users of thresholds that changed, use for loop instead of for-each loop
JS: When looping over users of thresholds that changed, use for loop instead of for-each loop

This change prevents a checkForComodification error in case the call to thresholdChanged() adds another item to the users list

Signed-off-by: Stephen Wong <6f34db11dd2258ec4ffa799eb0d7827f906cb1c6@ausenco.com>

jaamsim/jaamsim,jaamsim/jaamsim,jaamsim/jaamsim,jaamsim/jaamsim