Fixed errors created during cleanup.