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
Summary
In LineItemHandler there is a part where case for new ShoppingList creation is seemingly covered, but it's never called, and looks like dead code to me:
Summary
In LineItemHandler there is a part where case for new ShoppingList creation is seemingly covered, but it's never called, and looks like dead code to me:
https://github.com/oroinc/orocommerce/blob/master/src/Oro/Bundle/ShoppingListBundle/Form/Handler/LineItemHandler.php#L82-L89
This handler is called only in
\Oro\Bundle\ShoppingListBundle\Controller\Frontend\AjaxLineItemController::addProductFromViewAction
where ShoppingList is always created before, if it didn't exist:https://github.com/oroinc/orocommerce/blob/master/src/Oro/Bundle/ShoppingListBundle/Controller/Frontend/AjaxLineItemController.php#L59
https://github.com/oroinc/orocommerce/blob/master/src/Oro/Bundle/ShoppingListBundle/Controller/Frontend/Api/Rest/LineItemController.php#L144
\Oro\Bundle\ShoppingListBundle\Controller\Frontend\Api\Rest\LineItemController::putAction
which is responsible for updating a LineItem, so it must be assigned to a ShoppingList already.
JK
The text was updated successfully, but these errors were encountered: