Clean up dead code and imports