Open
Description
This issue is automatically created based on existing pull request: #31823: Update bundle price renderer docblock
Description
PHPStan fails when using the original block:
------ ---------------------------------------------------------------------------------------------------------------------
Line app/design/frontend/my/theme-x/Magento_Bundle/templates/email/order/items/creditmemo/default.phtml
------ ---------------------------------------------------------------------------------------------------------------------
25 Parameter #1 $item of method
Magento\Bundle\Block\Sales\Order\Items\Renderer::getItemPrice()
expects
Magento\Bundle\Block\Sales\Order\Items\CreditmemoItem|Magento\Bundle\
Block\Sales\Order\Items\InvoiceItem|Magento\Bundle\Block\Sales\Order\
Items\OrderItem, Magento\Sales\Model\Order\Item given.
------ ---------------------------------------------------------------------------------------------------------------------
default.phtml line 25:
<p class="item-price"><?= /* @noEscape */ $block->getItemPrice($item->getOrderItem()) ?></p>
Related Pull Requests
Fixed Issues (if relevant)
- Fixes magento/magento2#<issue_number>
Manual testing scenarios
- Configure PHPStan to run against your app/design files;
- Have the following line on your app/design/frontend/my/theme-x/Magento_Bundle/templates/email/order/items/creditmemo/default.phtml file:
<p class="item-price"><?= /* @noEscape */ $block->getItemPrice($item->getOrderItem()) ?></p>
Questions or comments
Contribution checklist (*)
- Pull request has a meaningful description of its purpose
- All commits are accompanied by meaningful commit messages
- All new or changed code is covered with unit/integration tests (if applicable)
- All automated tests passed successfully (all builds are green)
Metadata
Metadata
Assignees
Labels
Gate 3 Passed. Manual verification of the issue completed. Issue is confirmedMay be fixed according to the position in the backlog.Indicates original Magento version for the Issue report.The issue has been reproduced on latest 2.4-develop branchIssue related to Developer Experience and needs help with Triage to Confirm or Reject it