further reduce unnecessary code