Some minor cleanups and tweaks