Remove uses of console in JS.

Addresses https://joindin.jira.com/browse/JOINDIN-445