- public static void assertStrongPassword(String pw, User u) throws GigiApiException {
- if (checkpw(pw, u) < 3) {
+ public static void assertStrongPassword(String pw, Name[] names, String email) throws GigiApiException {
+ TreeSet<String> parts = new TreeSet<>();
+ for (int i = 0; i < names.length; i++) {
+ for (NamePart string : names[i].getParts()) {
+ parts.add(string.getValue());
+ }
+ }
+ if (checkpw(pw, parts.toArray(new String[parts.size()]), email) < 3) {