public void VirifyPassword(T password) { if (passwordCheckerService.VerifyPassword(password).Item1) { repository.Create(password); } }
static void Main(string[] args) { IPasswordCheckerService servie = Resolver.Get <IPasswordCheckerService>(); bool flag = false; while (!flag) { Console.WriteLine("Enter password:"); string password = Console.ReadLine(); var result = servie.VerifyPassword(password); foreach (Tuple <bool, string> tuple in result) { if (tuple.Item1) { flag = true; } Console.WriteLine(tuple.Item2); } } Console.ReadKey(); }