Fixed deprecated for..in loops to array.forEach