general cleaning of code format and names