When requesting /actions/commerce/payments/complete-payment?commerceTransactionHash=<hash> to complete order that has Custom Line items, getting an error: Cannot get a purchasable for a custom line item
exception: "yii\\base\\InvalidConfigException"
file: "/var/www/html/vendor/craftcms/commerce/src/models/LineItem.php"
line: 821
message: "Cannot get a purchasable for a custom line item"
name: "Invalid Configuration"
What happened?
Description
When requesting
/actions/commerce/payments/complete-payment?commerceTransactionHash=<hash>
to complete order that has Custom Line items, getting an error:Cannot get a purchasable for a custom line item
Steps to reproduce
/actions/commerce/payments/complete-payment?commerceTransactionHash=<hash>
to complete orederExpected behavior
Complete order without errors
Actual behavior
Order is marked as completed but throws an error
Craft CMS version
5.4.8
Craft Commerce version
5.2.0
PHP version
8.3
Operating system and version
ddev
Database type and version
mysql 8
Image driver and version
No response
Installed plugins and versions
-