Skip to content

Commit b7c76e3

Browse files
🔃 [EngCom] Public Pull Requests - 2.3-develop
Accepted Public Pull Requests: - #14684: [Forwardport] Fix for Issue #13950 - Cache issue with configurable products related to currency-conversions (by @rostyslav-hymon) - #14666: [Forwardport] Fixed 'Non-numeric value' warning on account create/save when DOB field is visible (by @rostyslav-hymon) - #14652: Eliminate usage of "else" statements (by @nuzil) - #13402: #13296: Category name with special characters brakes � (by @vinayshah) Fixed GitHub Issues: - #12146: Customer with empty "Date of Birth" cannot be saved (reported by @JanisE) has been fixed in #14666 by @rostyslav-hymon in 2.3-develop branch Related commits: 1. 4801d74 - #13296: Category name with special characters brakes in url rewrites category tree (reported by @galanis-a) has been fixed in #13402 by @vinayshah in 2.3-develop branch Related commits: 1. bd5834c 2. 46feb0b 3. aa31ff8 4. c136ce8 5. 9b67a3e 6. 6e1ac10 7. 9a73e4c 8. f6c4efd 9. b8b000b 10. 33144f9 11. 47b5440 12. 2ef98ac 13. 3ce79eb 14. 8b8d5ce 15. 2c97259 16. de3b966 17. 597d548 18. 30989e1 19. b9d2e53 20. b52787a
2 parents 4822bb1 + 2834b69 commit b7c76e3

File tree

26 files changed

+137
-66
lines changed

26 files changed

+137
-66
lines changed

app/code/Magento/Backend/Block/Widget/Grid/Column/Filter/Radio.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,7 @@ public function getCondition()
3131
{
3232
if ($this->getValue()) {
3333
return $this->getColumn()->getValue();
34-
} else {
35-
return [['neq' => $this->getColumn()->getValue()], ['is' => new \Zend_Db_Expr('NULL')]];
3634
}
35+
return [['neq' => $this->getColumn()->getValue()], ['is' => new \Zend_Db_Expr('NULL')]];
3736
}
3837
}

app/code/Magento/Backend/Block/Widget/Grid/Massaction/AbstractMassaction.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -223,9 +223,8 @@ public function getSelectedJson()
223223
if ($selected = $this->getRequest()->getParam($this->getFormFieldNameInternal())) {
224224
$selected = explode(',', $selected);
225225
return join(',', $selected);
226-
} else {
227-
return '';
228226
}
227+
return '';
229228
}
230229

231230
/**
@@ -238,9 +237,8 @@ public function getSelected()
238237
if ($selected = $this->getRequest()->getParam($this->getFormFieldNameInternal())) {
239238
$selected = explode(',', $selected);
240239
return $selected;
241-
} else {
242-
return [];
243240
}
241+
return [];
244242
}
245243

246244
/**

app/code/Magento/Backend/Block/Widget/Grid/Massaction/Extended.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -219,9 +219,8 @@ public function getSelectedJson()
219219
if ($selected = $this->getRequest()->getParam($this->getFormFieldNameInternal())) {
220220
$selected = explode(',', $selected);
221221
return join(',', $selected);
222-
} else {
223-
return '';
224222
}
223+
return '';
225224
}
226225

227226
/**
@@ -234,9 +233,8 @@ public function getSelected()
234233
if ($selected = $this->getRequest()->getParam($this->getFormFieldNameInternal())) {
235234
$selected = explode(',', $selected);
236235
return $selected;
237-
} else {
238-
return [];
239236
}
237+
return [];
240238
}
241239

242240
/**

app/code/Magento/Backend/Controller/Adminhtml/Auth/Login.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,8 @@ public function execute()
5050
// redirect according to rewrite rule
5151
if ($requestUrl != $backendUrl) {
5252
return $this->getRedirect($backendUrl);
53-
} else {
54-
return $this->resultPageFactory->create();
5553
}
54+
return $this->resultPageFactory->create();
5655
}
5756

5857
/**

app/code/Magento/Backend/Controller/Adminhtml/System/Account/Save.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,8 @@ private function getSecurityCookie()
3232
{
3333
if (!($this->securityCookie instanceof SecurityCookie)) {
3434
return \Magento\Framework\App\ObjectManager::getInstance()->get(SecurityCookie::class);
35-
} else {
36-
return $this->securityCookie;
3735
}
36+
return $this->securityCookie;
3837
}
3938

4039
/**

app/code/Magento/Backend/Model/Menu/Item.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -503,12 +503,11 @@ public function populateFromArray(array $data)
503503
$this->_tooltip = $this->_getArgument($data, 'toolTip');
504504
$this->_title = $this->_getArgument($data, 'title');
505505
$this->target = $this->_getArgument($data, 'target');
506+
$this->_submenu = null;
506507
if (isset($data['sub_menu'])) {
507508
$menu = $this->_menuFactory->create();
508509
$menu->populateFromArray($data['sub_menu']);
509510
$this->_submenu = $menu;
510-
} else {
511-
$this->_submenu = null;
512511
}
513512
}
514513
}

app/code/Magento/Braintree/Test/Unit/Model/Report/BraintreeTransactionStub.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,9 @@ public function __get($name)
3434
{
3535
if (array_key_exists($name, $this->_attributes)) {
3636
return $this->_attributes[$name];
37-
} else {
38-
trigger_error('Undefined property on ' . get_class($this) . ': ' . $name, E_USER_NOTICE);
39-
return null;
4037
}
38+
trigger_error('Undefined property on ' . get_class($this) . ': ' . $name, E_USER_NOTICE);
39+
return null;
4140
}
4241

4342
/**

app/code/Magento/Bundle/Block/Adminhtml/Sales/Order/Items/Renderer.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,9 +95,8 @@ public function getChildren($item)
9595

9696
if (isset($itemsArray[$item->getOrderItem()->getId()])) {
9797
return $itemsArray[$item->getOrderItem()->getId()];
98-
} else {
99-
return null;
10098
}
99+
return null;
101100
}
102101

103102
/**
@@ -219,9 +218,8 @@ public function getOrderItem()
219218
{
220219
if ($this->getItem() instanceof \Magento\Sales\Model\Order\Item) {
221220
return $this->getItem();
222-
} else {
223-
return $this->getItem()->getOrderItem();
224221
}
222+
return $this->getItem()->getOrderItem();
225223
}
226224

227225
/**

app/code/Magento/Bundle/Block/Catalog/Product/View/Type/Bundle/Option.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -189,9 +189,8 @@ public function isSelected($selection)
189189
return in_array($selection->getSelectionId(), $selectedOptions);
190190
} elseif ($selectedOptions == 'None') {
191191
return false;
192-
} else {
193-
return $selection->getIsDefault() && $selection->isSaleable();
194192
}
193+
return $selection->getIsDefault() && $selection->isSaleable();
195194
}
196195

197196
/**

app/code/Magento/Bundle/Block/Sales/Order/Items/Renderer.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -142,9 +142,8 @@ public function getValueHtml($item)
142142
if ($attributes = $this->getSelectionAttributes($item)) {
143143
return sprintf('%d', $attributes['qty']) . ' x ' . $this->escapeHtml($item->getName()) . " "
144144
. $this->getOrder()->formatPrice($attributes['price']);
145-
} else {
146-
return $this->escapeHtml($item->getName());
147145
}
146+
return $this->escapeHtml($item->getName());
148147
}
149148

150149
/**
@@ -179,9 +178,8 @@ public function getChildren($item)
179178

180179
if (isset($itemsArray[$item->getOrderItem()->getId()])) {
181180
return $itemsArray[$item->getOrderItem()->getId()];
182-
} else {
183-
return null;
184181
}
182+
return null;
185183
}
186184

187185
/**

0 commit comments

Comments
 (0)