Avoid Duplicate Line-Items due to Misaligned Letter Casing
Not everyone is aware, but the SerializableCart in Episerver Commerce is by default case sensitive on SKU. It means that features relying on a free-form approach to add to cart features, like Order Entry, potentially creates duplicate line items, which might skew your cart experience and influence your marketing promotions.
Instead of always validating the entry against your catalog, to apply the right upper casing, you can rely on these snippets to continuously enforce a similar business rule.
It’s a two-part exercise – first and foremost, we iterate through the entire cart and modify the letter casing across all inconsistent line items. Secondly, potential conflicting SKUs are now merged to a single line item to avoid line duplication.
Similarly to the way you use existing workflows within Episerver Commerce, you can now execute these processes as part of your cart validation.
Very simple, yet highly practical.