Describe your bug or feature request.
The promotion usage is currently incorrectly registered as we're registering usage for each promotion adjustment found.
Considering promotions are split across order items, the same promotion is registered for each order item. (i.e if the order has 20 items, the promotion usage is going to be registered 20 times).
The DB itself should probably have a unique constraint on a composite key (promotion_id, order_id).
But in the meantime, we should at the very least fix the logic that's registering the usage from the event subscriber reacting to the order place event.
Comments
Comment #2
jsacksick commentedComment #5
jsacksick commentedCommitted!