Improved error-handling for reset password routes