Formatting and comment refactoring