changed the reset button to work properly