implemented reset for input