/// <summary>
 /// when bad login attempt happend this method is called and increase count
 /// if the count hits 3 card is blocked
 /// </summary>
 /// <param name="cardName"></param>
 /// <returns></returns>
 public bool AddBadAttempt(string cardName)
 {
     if (!badAttemptsCount.Keys.Contains(cardName))
     {
         badAttemptsCount.Add(cardName, 1);
     }
     else
     {
         badAttemptsCount[cardName]++;
     }
     if (badAttemptsCount[cardName] == 3)
     {
         cardsRepo.BlockUnblockCard(cardName);
         return(false);
     }
     ///in case we reset the card
     else if (badAttemptsCount[cardName] > 3)
     {
         ResetBadAttempts(cardName);
     }
     return(true);
 }
        /// <summary>
        /// block or unblock card, always change the value
        /// </summary>
        /// <param name="creditCardNumber"></param>

        public void BlockUnblockCard(string creditCardNumber)
        {
            cardsRepo.BlockUnblockCard(creditCardNumber);
        }