Made the .forEach statements work in IE8