Fixed remove unnecessary code