Skip to content

Commit 6103b6b

Browse files
🔃 [EngCom] Public Pull Requests - 2.1-develop
Accepted Public Pull Requests: - #15619: Fix incorrect type hinting in PHPDocs (by @dmytro-ch) - #15563: [Backport] Correct functions return statement (by @rogyar) - #15522: [Backlog] Add resetting of triggerRecollection flag (by @rogyar) - #15445: [Backport] Fix unnecessary recalculation of product list pricing (by @JeroenVanLeusden) Fixed GitHub Issues: - #13992: Incorrect phpdoc should be Shipment\Item not Invoice\Item (reported by @ThisIsRuddy) has been fixed in #15619 by @dmytro-ch in 2.1-develop branch Related commits: 1. ab64a2c - #9580: Quote Attribute trigger_recollect causes a timeout (reported by @bh-ref) has been fixed in #15522 by @rogyar in 2.1-develop branch Related commits: 1. bddb976 - #14941: Unnecessary recalculation of product list pricing causes huge slowdowns (reported by @paales) has been fixed in #15445 by @JeroenVanLeusden in 2.1-develop branch Related commits: 1. 3d05e6b
2 parents 1a099cb + d871eb8 commit 6103b6b

File tree

5 files changed

+11
-9
lines changed

5 files changed

+11
-9
lines changed

app/code/Magento/Quote/Model/Quote.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2363,13 +2363,17 @@ public function merge(Quote $quote)
23632363
* Trigger collect totals after loading, if required
23642364
*
23652365
* @return $this
2366+
* @throws \Exception
23662367
*/
23672368
protected function _afterLoad()
23682369
{
23692370
// collect totals and save me, if required
23702371
if (1 == $this->getData('trigger_recollect')) {
2371-
$this->collectTotals()->save();
2372+
$this->collectTotals()
2373+
->setTriggerRecollect(0)
2374+
->save();
23722375
}
2376+
23732377
return parent::_afterLoad();
23742378
}
23752379

app/code/Magento/Sales/Model/Order/Shipment/Item.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -146,8 +146,7 @@ public function getOrderItem()
146146
* Declare qty
147147
*
148148
* @param float $qty
149-
* @return \Magento\Sales\Model\Order\Invoice\Item
150-
* @throws \Magento\Framework\Exception\LocalizedException
149+
* @return $this
151150
*/
152151
public function setQty($qty)
153152
{
@@ -159,7 +158,6 @@ public function setQty($qty)
159158
* Applying qty to order item
160159
*
161160
* @return $this
162-
* @throws \Magento\Framework\Exception\LocalizedException
163161
*/
164162
public function register()
165163
{

app/code/Magento/SalesRule/Controller/Adminhtml/Promo/Quote.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ protected function _initRule()
7474
/**
7575
* Initiate action
7676
*
77-
* @return this
77+
* @return $this
7878
*/
7979
protected function _initAction()
8080
{

app/code/Magento/Security/Model/AdminSessionInfo.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ public function isOtherSessionsTerminated()
154154
* Setter for isOtherSessionsTerminated
155155
*
156156
* @param bool $isOtherSessionsTerminated
157-
* @return this
157+
* @return $this
158158
*/
159159
public function setIsOtherSessionsTerminated($isOtherSessionsTerminated)
160160
{

app/code/Magento/Tax/Model/Config.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -831,20 +831,20 @@ public function getInfoUrl($store = null)
831831
* If it necessary will be returned conversion type (minus or plus)
832832
*
833833
* @param null|int|string|Store $store
834-
* @return bool
834+
* @return bool|int
835835
* @SuppressWarnings(PHPMD.CyclomaticComplexity)
836836
*/
837837
public function needPriceConversion($store = null)
838838
{
839-
$res = false;
839+
$res = 0;
840840
$priceIncludesTax = $this->priceIncludesTax($store) || $this->getNeedUseShippingExcludeTax();
841841
if ($priceIncludesTax) {
842842
switch ($this->getPriceDisplayType($store)) {
843843
case self::DISPLAY_TYPE_EXCLUDING_TAX:
844844
case self::DISPLAY_TYPE_BOTH:
845845
return self::PRICE_CONVERSION_MINUS;
846846
case self::DISPLAY_TYPE_INCLUDING_TAX:
847-
$res = true;
847+
$res = false;
848848
break;
849849
default:
850850
break;

0 commit comments

Comments
 (0)