chore(medusa): Little improvement in draft order creation (#3374)
**What** Only call line item service create once, instead of twice.
This commit is contained in:
committed by
GitHub
parent
d0d11307d2
commit
84e4489683
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"@medusajs/medusa": patch
|
||||
---
|
||||
|
||||
chore(medusa): Little improvement in draft order creation
|
||||
@@ -352,7 +352,7 @@ class DraftOrderService extends TransactionBaseService {
|
||||
cart_id: createdCart.id,
|
||||
}))
|
||||
|
||||
promises.push(lineItemServiceTx.create(toCreate))
|
||||
itemsToCreate.push(...toCreate)
|
||||
}
|
||||
|
||||
// custom line items can be added to a draft order
|
||||
|
||||
Reference in New Issue
Block a user