Remove some unnecessary code