From 020c1b0bc39d18f4b5eca21249403dc47e2a22ca Mon Sep 17 00:00:00 2001 From: hydrogen Date: Fri, 4 Dec 2020 16:53:00 +0200 Subject: [PATCH] fix: rename function --- ui/imports/Utils.qml | 3 +-- ui/onboarding/CreatePasswordModal.qml | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/ui/imports/Utils.qml b/ui/imports/Utils.qml index 38cd90b22e..1c29ea4873 100644 --- a/ui/imports/Utils.qml +++ b/ui/imports/Utils.qml @@ -198,8 +198,7 @@ QtObject { } } - function validate(item, firstPasswordField, repeatPasswordField) { - console.log("validate"); + function validatePasswords(item, firstPasswordField, repeatPasswordField) { switch (item) { case "first": if (firstPasswordField.text === "") { diff --git a/ui/onboarding/CreatePasswordModal.qml b/ui/onboarding/CreatePasswordModal.qml index fd9df3c9ba..cbc950d036 100644 --- a/ui/onboarding/CreatePasswordModal.qml +++ b/ui/onboarding/CreatePasswordModal.qml @@ -34,7 +34,7 @@ ModalPopup { validationError: popup.passwordValidationError onTextChanged: { [firstPasswordFieldValid, passwordValidationError] = - Utils.validate("first", firstPasswordField, repeatPasswordField); + Utils.validatePasswords("first", firstPasswordField, repeatPasswordField); } } @@ -56,7 +56,7 @@ ModalPopup { } onTextChanged: { [repeatPasswordFieldValid, repeatPasswordValidationError] = - Utils.validate("repeat", firstPasswordField, repeatPasswordField); + Utils.validatePasswords("repeat", firstPasswordField, repeatPasswordField); } }