cleaning and rename code