Clean up metadata