Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/lib/screens/mobile_registration_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ class _MobileRegistrationScreenState extends State<MobileRegistrationScreen> {
});

bool seedWordConfirmationValidation = validateSeedWords(
_registrationData.phrase, seedConfirmationController.text);
_registrationData.phrase, seedCheckValue);

if (seedWordConfirmationValidation) {
setState(() {
Expand Down
5 changes: 4 additions & 1 deletion app/lib/services/tools_service.dart
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@ bool validateSeedWords(String seed, String confirmationWords) {
List<String> seedWords = seed.split(' ');

// if length is not correct return already here
if (words.length != 3) return false;
if (words.length < 3) return false;
if (words.length < 3 || words.toSet().length < 3) {
return false;
}

for (final String word in words) {
// check every word in list against the seed
Expand Down