Running synth.js through jslint and make corrections