You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am currently developing the frontend for my e-commerce platform. While testing the discount component, I created a coupon code through the admin dashboard and successfully applied it on the frontend. However, when I attempted to decrement the quantity of an item while the discount code is applied from the cart, an error occurred but if it try to remove the item there is no error.
Expected behavior
The item should have remove from the cart and then all the amount get adjusted accordingly.
Actual behavior
below error was thown in backend console.
http: POST /store/carts/cart_01JH31JR1GB4RP09DNPAZGYW5P/line-items/cali_01JH362WQV95FKF05FB8KHHXFH ← - (200) - 2476.881 ms
http: GET /store/carts/cart_01JH31JR1GB4RP09DNPAZGYW5P?fields=%2Aitems%2C%20%2Aregion%2C%20%2Aitems.product%2C%20%2Aitems.variant%2C%20%2Aitems.thumbnail%2C%20%2Aitems.metadata%2C%20%2Bitems.total%2C%20%2Apromotions ← - (200) - 34.648 ms
error: Cannot read properties of undefined (reading 'actor_id')
TypeError: Cannot read properties of undefined (reading 'actor_id')
at GET (D:\Project\backend\src\api\store\customers\i\route.ts:8:33)
at D:\Project\backend\node_modules@medusajs\utils\src\common\wrap-handler.ts:17:20
at Layer.handle [as handle_request] (D:\Project\backend\node_modules\express\lib\router\layer.js:95:5)
at next (D:\Project\backend\node_modules\express\lib\router\route.js:149:13)
at Route.dispatch (D:\Project\backend\node_modules\express\lib\router\route.js:119:3)
at Layer.handle [as handle_request] (D:\Project\backend\node_modules\express\lib\router\layer.js:95:5)
at D:\Project\backend\node_modules\express\lib\router\index.js:284:15
at Function.process_params (D:\Project\backend\node_modules\express\lib\router\index.js:346:12)
at next (D:\Project\backend\node_modules\express\lib\router\index.js:280:10)
at next (D:\Project\backend\node_modules\express\lib\router\route.js:141:14)
second try to decrement quantity of item from cart
error: Invalid BigNumber value: null. Should be one of: string, number, BigNumber (bignumber.js), BigNumberRawValue
{
message: 'Invalid BigNumber value: null. Should be one of: string, number, BigNumber (bignumber.js), BigNumberRawValue',
name: 'Error',
stack: 'Error: Invalid BigNumber value: null. Should be one of: string, number, BigNumber (bignumber.js), BigNumberRawValue\n' +
' at BigNumber.setRawValueOrThrow (D:\Project\backend\node_modules\@medusajs\utils\src\totals\big-number.ts:76:13)\n' +
' at new BigNumber (D:\Project\backend\node_modules\@medusajs\utils\src\totals\big-number.ts:16:10)\n' +
' at MikroORMEntity.set [as amount] (D:\Project\backend\node_modules\@medusajs\utils\src\dal\mikro-orm\big-number-field.ts:42:25)\n' +
' at eval (eval at createFunction (D:\Project\backend\node_modules\@mikro-orm\core\utils\Utils.js:833:20), :9:57)\n' +
' at Function.callCompiledFunction (D:\Project\backend\node_modules\@mikro-orm\core\utils\Utils.js:844:20)\n' +
' at ObjectHydrator.hydrate (D:\Project\backend\node_modules\@mikro-orm\core\hydration\ObjectHydrator.js:27:23)\n' +
' at EntityFactory.hydrate (D:\Project\backend\node_modules\@mikro-orm\core\entity\EntityFactory.js:203:27)\n' +
' at EntityFactory.create (D:\Project\backend\node_modules\@mikro-orm\core\entity\EntityFactory.js:56:18)\n' +
' at SqlEntityManager.create (D:\Project\backend\node_modules\@mikro-orm\core\EntityManager.js:980:41)\n' +
' at D:\Project\backend\node_modules\@medusajs\utils\src\dal\mikro-orm\mikro-orm-repository.ts:353:24\n' +
'⮑ sat D:\Project\backend\node_modules\@medusajs\core-flows\dist\cart\workflows\update-cart-promotions.js: [update-cart-promotions -> create-line-item-adjustments (invoke)]\n' +
'⮑ sat D:\Project\backend\node_modules\@medusajs\core-flows\dist\cart\workflows\refresh-cart-items.js: [refresh-cart-items -> update-cart-promotions-as-step (invoke)]\n' +
'⮑ sat D:\Project\backend\node_modules\@medusajs\core-flows\dist\cart\workflows\update-line-item-in-cart.js: [update-line-item-in-cart -> refresh-cart-items-as-step (invoke)]'
}
info: Processing LinkCartPromotion.attached which has 0 subscribers
http: POST /store/carts/cart_01JH31JR1GB4RP09DNPAZGYW5P/line-items/cali_01JH362WQV95FKF05FB8KHHXFH ← - (500) - 2208.933 ms
Link to reproduction repo
NA
The text was updated successfully, but these errors were encountered:
A reproduction repo will be needed before we can debug this issue. For now, I will close the issue. However, feel free to reply with a link to the reproduction repo
Package.json file
Node.js version
v20.18.1
Database and its version
PostgreSQL 17.2
Operating system name and version
Windows 11
Browser name
No response
What happended?
I am currently developing the frontend for my e-commerce platform. While testing the discount component, I created a coupon code through the admin dashboard and successfully applied it on the frontend. However, when I attempted to decrement the quantity of an item while the discount code is applied from the cart, an error occurred but if it try to remove the item there is no error.
Expected behavior
The item should have remove from the cart and then all the amount get adjusted accordingly.
Actual behavior
below error was thown in backend console.
second try to decrement quantity of item from cart
Link to reproduction repo
NA
The text was updated successfully, but these errors were encountered: