Remove dead imports and delete more dead code