Implementing functionality for reset button