From 2aa38ff40fd56a0171fd7a80847fd5a36b817e26 Mon Sep 17 00:00:00 2001 From: Maksym Novik Date: Thu, 23 May 2019 13:03:43 +0300 Subject: [PATCH] Msi 2182 source entity expansion with pickup location attributes. LocalizedException -> InvalidArgumentException --- .../Magento/InventoryInStorePickupApi/Model/Mapper.php | 9 +++------ .../Magento/InventoryInStorePickupApi/i18n/en_US.csv | 1 - 2 files changed, 3 insertions(+), 7 deletions(-) delete mode 100644 app/code/Magento/InventoryInStorePickupApi/i18n/en_US.csv diff --git a/app/code/Magento/InventoryInStorePickupApi/Model/Mapper.php b/app/code/Magento/InventoryInStorePickupApi/Model/Mapper.php index 1729b203164f..0b5341ff1a40 100644 --- a/app/code/Magento/InventoryInStorePickupApi/Model/Mapper.php +++ b/app/code/Magento/InventoryInStorePickupApi/Model/Mapper.php @@ -7,7 +7,6 @@ namespace Magento\InventoryInStorePickupApi\Model; -use Magento\Framework\Exception\LocalizedException; use Magento\InventoryApi\Api\Data\SourceInterface; use Magento\InventoryInStorePickupApi\Api\Data\PickupLocationInterface; use Magento\InventoryInStorePickupApi\Model\Mapper\CreateFromSourceInterface; @@ -55,11 +54,9 @@ public function __construct( foreach ($preProcessors as $preProcessor) { if (!$preProcessor instanceof PreProcessorInterface) { - throw new LocalizedException( - __( - 'Source Data PreProcessor must implement %1.', - PreProcessorInterface::class - ) + throw new \InvalidArgumentException( + 'Source Data PreProcessor must implement %1.', + PreProcessorInterface::class ); } } diff --git a/app/code/Magento/InventoryInStorePickupApi/i18n/en_US.csv b/app/code/Magento/InventoryInStorePickupApi/i18n/en_US.csv deleted file mode 100644 index be3e1c2ee00d..000000000000 --- a/app/code/Magento/InventoryInStorePickupApi/i18n/en_US.csv +++ /dev/null @@ -1 +0,0 @@ -"Source Data Pre Processor must implement %1.","Source Data Pre Processor must implement %1."