Make javascript indenting consistent

This makes the javascript indenting consistent to 4 char indents
(which much of the file used), which helps make the flow and blocking
a little clearer.

It also adds ; where js2-mode (emacs js ide) indicated they were
potentially ambiguous.

Signed-off-by: Sean Dague <sean@dague.net>