a few cleanups
Merge pull request #477 from metamx/minor-cleanup

A few minor cleanups and fixes