Fixed some more styling
Fixed errors detected by jslint