Clean up comments and code order in the provider