/// <summary> /// Checks if the amount requested is valid. /// </summary> /// <param name="amountRequested"></param> private void CheckRequestedAmountValid(int amountRequested) { bool amountRequestedValid = _conditionService.IsAmountRequestedValid(amountRequested); if (amountRequestedValid) { return; } var exception = new Exception($"{amountRequested} is not within the accepted criteria."); _logger.LogError(exception.Message, exception); throw exception; }