removed some non needed code that gave errors