clean ugly line of code