Added a reset function
Added a route for resetting