fixed minor bugs in reset.php