Skip to content
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

Fix static analysis issues #133

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

ahasAmp
Copy link
Contributor

@ahasAmp ahasAmp commented Dec 8, 2023

vendor/ampersand/magento2-disable-stock-reservation/src/Model/GetInventoryRequestFromOrder.php
111 Expression on left side of ?? is not nullable.
114 Expression on left side of ?? is not nullable.

36 Property Ampersand\DisableStockReservation\Plugin\Model\OrderRepositoryPlugin::$sourceSelectionResultInterfaceFactory is never read, only written.

65 Property
Ampersand\DisableStockReservation\Plugin\SourceDeductionProcessor::$orderExtensionFactoryis never read, only written.

@ahasAmp ahasAmp changed the title Update GetInventoryRequestFromOrder.php Fix static analysis issues Dec 8, 2023
@ahasAmp ahasAmp self-assigned this Dec 8, 2023
@@ -108,10 +108,10 @@ private function getAddressFromOrder(OrderInterface $order): ?AddressInterface

return $this->addressInterfaceFactory->create([
'country' => $shippingAddress->getCountryId(),
'postcode' => $shippingAddress->getPostcode() ?? '',
'postcode' => $shippingAddress->getPostcode() ? $shippingAddress->getPostcode() : '',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Screenshot 2023-12-08 at 16 04 19
https://www.php.net/manual/en/migration70.new-features.php

Not sure whats complaining here, this seems like an old way of doing it? or am i completely misinterpreting this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants