Example #1
0
        public bool DeleteBasket(int basketId)
        {
            var model = new bool();

            using (var client = new ToteService.BetListServiceClient())
            {
                try
                {
                    client.Open();
                    model = client.DeleteBasket(basketId);
                    client.Close();
                }

                catch (FaultException <CustomException> customEx)
                {
                    log.Error(customEx.Message);
                    return(false);
                }
                catch (CommunicationException commEx)
                {
                    log.Error(commEx.Message);
                    return(false);
                }
            }
            return(model);
        }