-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
used product link from metadataPool instead of getId for Adobe commerce #142
base: master
Are you sure you want to change the base?
used product link from metadataPool instead of getId for Adobe commerce #142
Conversation
@zans-laksa @carinadues Please review the PR |
@aleksandrsm can you please do CR? |
src/Model/Variant/Collection.php
Outdated
@@ -255,7 +255,8 @@ protected function getChildCollectionMapAndList(): array { | |||
$childProductsList = []; | |||
|
|||
$parentIds = array_map(function ($product) { | |||
return $product->getId(); | |||
$linkField = $this->metadataPool->getMetadata(ProductInterface::class)->getLinkField(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
here and in other places: only load $linkField ones, there is no need to check it inside each array/foreach iteration, it will not change
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@aleksandrsm Updated the changes, please check
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see comment
@NavaneethVijay Thank you! This will be added in an upcoming release. |
Fixes scandipwa/scandipwa#5194