Tidy up imports and whitespace