Formatting and bugfix