]> WPIA git - gigi.git/blobdiff - src/org/cacert/gigi/pages/account/MyDetailsForm.java
UPD: desired behavior should only enforce a persons last name.
[gigi.git] / src / org / cacert / gigi / pages / account / MyDetailsForm.java
index 74e454542dc8f6e6c4bdf159ce30a06ee12a759e..359880b409b706c19f8a4b6563a9c6544616dac1 100644 (file)
@@ -42,8 +42,8 @@ public class MyDetailsForm extends Form {
                 String newLname = req.getParameter("lname").trim();
                 String newMname = req.getParameter("mname").trim();
                 String newSuffix = req.getParameter("suffix").trim();
-                if (newFname.isEmpty() && !target.getFname().isEmpty()) {
-                    throw new GigiApiException("Names couldn't be removed.");
+                if (newLname.isEmpty()) {
+                    throw new GigiApiException("Last name cannot be empty.");
                 }
                 target.setFname(newFname);
                 target.setLname(newLname);