Some improvements and cleaning.