delete redundent code