From 0a64152e4b2bc61891343bb49ed11f1dc874c8bc Mon Sep 17 00:00:00 2001 From: Muhammad Umer Date: Tue, 7 Nov 2023 01:06:18 +0500 Subject: [PATCH] chore: address feedback --- .../Authorization/Presentation/Login/SignInViewModel.swift | 2 +- Authorization/Authorization/SwiftGen/Strings.swift | 4 ++-- Authorization/Authorization/en.lproj/Localizable.strings | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Authorization/Authorization/Presentation/Login/SignInViewModel.swift b/Authorization/Authorization/Presentation/Login/SignInViewModel.swift index 9f70cc70e..596da12b7 100644 --- a/Authorization/Authorization/Presentation/Login/SignInViewModel.swift +++ b/Authorization/Authorization/Presentation/Login/SignInViewModel.swift @@ -54,7 +54,7 @@ public class SignInViewModel: ObservableObject { errorMessage = AuthLocalization.Error.invalidEmailAddressOrUsername return } - guard validator.isValidPassword(password) else { + guard !password.isEmpty else { errorMessage = AuthLocalization.Error.invalidPasswordLength return } diff --git a/Authorization/Authorization/SwiftGen/Strings.swift b/Authorization/Authorization/SwiftGen/Strings.swift index 9f0f21041..aa8fe2f35 100644 --- a/Authorization/Authorization/SwiftGen/Strings.swift +++ b/Authorization/Authorization/SwiftGen/Strings.swift @@ -11,8 +11,8 @@ import Foundation // swiftlint:disable nesting type_body_length type_name vertical_whitespace_opening_braces public enum AuthLocalization { public enum Error { - /// Invalid email - public static let invalidEmailAddress = AuthLocalization.tr("Localizable", "ERROR.INVALID_EMAIL_ADDRESS", fallback: "Invalid email") + /// Invalid email address + public static let invalidEmailAddress = AuthLocalization.tr("Localizable", "ERROR.INVALID_EMAIL_ADDRESS", fallback: "Invalid email address") /// Invalid email or username public static let invalidEmailAddressOrUsername = AuthLocalization.tr("Localizable", "ERROR.INVALID_EMAIL_ADDRESS_OR_USERNAME", fallback: "Invalid email or username") /// Invalid password length diff --git a/Authorization/Authorization/en.lproj/Localizable.strings b/Authorization/Authorization/en.lproj/Localizable.strings index 114c2417a..8c58b2406 100644 --- a/Authorization/Authorization/en.lproj/Localizable.strings +++ b/Authorization/Authorization/en.lproj/Localizable.strings @@ -15,7 +15,7 @@ "SIGN_IN.FORGOT_PASS_BTN" = "Forgot password?"; "SIGN_IN.LOG_IN_BTN" = "Sign in"; -"ERROR.INVALID_EMAIL_ADDRESS" = "Invalid email"; +"ERROR.INVALID_EMAIL_ADDRESS" = "Invalid email address"; "ERROR.INVALID_EMAIL_ADDRESS_OR_USERNAME" = "Invalid email or username"; "ERROR.INVALID_PASSWORD_LENGTH" = "Invalid password length";