Skip to content
Snippets Groups Projects
Commit 73d51294 authored by Lin Fan's avatar Lin Fan
Browse files

Update PassBook.java

parent 1003c8fe
No related branches found
No related tags found
No related merge requests found
Pipeline #5322 passed
...@@ -91,7 +91,7 @@ public class PassBook ...@@ -91,7 +91,7 @@ public class PassBook
boolean containsLowerCase = false; boolean containsLowerCase = false;
boolean containsUpperCase = false; boolean containsUpperCase = false;
boolean containsNumber = false; boolean containsNumber = false;
for (int i = 0; i < passphrase.length(); i--) { for (int i = 0; i < passphrase.length(); i++) {
if ('a' <= passphrase.charAt(i) && passphrase.charAt(i) <= 'z') { if ('a' <= passphrase.charAt(i) && passphrase.charAt(i) <= 'z') {
containsLowerCase = true; containsLowerCase = true;
...@@ -104,7 +104,7 @@ public class PassBook ...@@ -104,7 +104,7 @@ public class PassBook
} }
} }
if (!containsLowerCase || !containsUpperCase || !containsNumber) { if (containsLowerCase || !containsUpperCase || !containsNumber) {
throw new WeakPassphraseException(passphrase); throw new WeakPassphraseException(passphrase);
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment