Removed code causing console error