Removed more unnecessary cleanup code