From e12eeaac9a1892bab43b8ab7083e03922da3b2ab Mon Sep 17 00:00:00 2001 From: David Alger Date: Wed, 10 Apr 2019 15:58:26 -0500 Subject: [PATCH 1/2] Backport #22281 (commit 8434d74abd6) fixing #15090 on 2.2 allowing admin/url/use_custom in env.php --- .../Magento/Config/Model/Config/Backend/Admin/Usecustom.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/code/Magento/Config/Model/Config/Backend/Admin/Usecustom.php b/app/code/Magento/Config/Model/Config/Backend/Admin/Usecustom.php index 9a483de6a695b..d12569eebe5b2 100644 --- a/app/code/Magento/Config/Model/Config/Backend/Admin/Usecustom.php +++ b/app/code/Magento/Config/Model/Config/Backend/Admin/Usecustom.php @@ -56,8 +56,9 @@ public function beforeSave() { $value = $this->getValue(); if ($value == 1) { - $customUrl = $this->getData('groups/url/fields/custom/value'); - if (empty($customUrl)) { + $customUrlField = $this->getData('groups/url/fields/custom/value'); + $customUrlConfig = $this->_config->getValue('admin/url/custom'); + if (empty($customUrlField) && empty($customUrlConfig)) { throw new \Magento\Framework\Exception\LocalizedException(__('Please specify the admin custom URL.')); } } From e1f91d1a87dabac77264f40992007124b8febd4e Mon Sep 17 00:00:00 2001 From: Lorenzo Stramaccia Date: Thu, 21 Mar 2019 10:48:53 +0100 Subject: [PATCH 2/2] Fix importFromArray by setting _isCollectionLoaded to true after import --- .../Magento/Eav/Model/Entity/Collection/AbstractCollection.php | 1 + 1 file changed, 1 insertion(+) diff --git a/app/code/Magento/Eav/Model/Entity/Collection/AbstractCollection.php b/app/code/Magento/Eav/Model/Entity/Collection/AbstractCollection.php index 7ac77a66482b8..242a44d9dabfd 100644 --- a/app/code/Magento/Eav/Model/Entity/Collection/AbstractCollection.php +++ b/app/code/Magento/Eav/Model/Entity/Collection/AbstractCollection.php @@ -1035,6 +1035,7 @@ public function importFromArray($arr) $this->_items[$entityId]->addData($row); } } + $this->_setIsLoaded(); return $this; }