public void RemoveShoppingCartItem(LineItem item) { // remove item var itemList = ShoppingCartItems.ToList(); itemList.Remove(item); ShoppingCartItems = itemList; // check coupons if not valid then remvove the coupon var lineCoupons = ShoppingCartCoupons.ToList(); var coupons = ShoppingCartCoupons.Select(sc => sc.Coupon); foreach (var c in coupons) { if (!c.IsCouponRulesApplicable(itemList)) { c.Remove(this); lineCoupons.Remove(ShoppingCartCoupons.SingleOrDefault(sc => sc.CouponId == c.Id)); } } ShoppingCartCoupons = lineCoupons; }