Added console error prevention for browsers that lack a console.