Formatting and whitespace cleanup