I'm having an issue where my Cart.Line.Increased code runs twice, this only happens when i change the quantity of the IncreasedLine.
Changing item.IncreasedLine.Quantity triggers the subscriber again.
So if I increment my item.IncreasedLine by 1, otherOrderline.Quantity gets increased by 2 instead of 1.
Also for some reason i do not understand, this code does not run in a loop, but only twice.
I'm running DW version 9.16.7
//find another orderline with the same product number but different variant code, and add the remaining quantity to that orderline var otherOrderline = item.IncreasedLine.Order.OrderLines.FirstOrDefault(ol => ol.ProductNumber == productNumber && ol.ProductVariantId != variantCode); if (otherOrderline != null) { //removing this, makes the code stop running twice item.IncreasedLine.Quantity = matchingPriceLine.QuantityInStock; otherOrderline.Quantity += item.AmountIncreased; }