remove of unnecessary code