A couple small style nits based on http://google-styleguide.googlecode.com/svn/trunk/javascriptguide.xml (which we try to follow):
- Please either put an entire if statement on one line or use {}.
- put a space between the "if" and the "(".