- try {
- for (int i = 0; i < 25; i++) {
- User a = getAgent(i);
- Notary.verify(byEmail, a, a.getNames()[0], a.getDoB(), 10, "Testmanager exp up code", validVerificationDateString(), VerificationType.FACE_TO_FACE, getRandomCountry());
+ if (byEmail == null || !byEmail.canVerify()) {
+ resp.getWriter().println("User not found, or found user is not allowed to verify.");
+ } else {
+ try {
+ for (int i = 0; i < 25; i++) {
+ User a = getAgent(i);
+ Notary.verify(byEmail, a, a.getNames()[0], a.getDoB(), 10, "Testmanager exp up code", validVerificationDateString(), VerificationType.FACE_TO_FACE, getRandomCountry());
+ }
+ resp.getWriter().println("Successfully added experience points.");
+ } catch (GigiApiException e) {
+ throw new Error(e);