fixed the reset issue