removes useless code