Misc formatting and variable fixes.