diff --git a/Component/CatalogPriceRules.php b/Component/CatalogPriceRules.php
index 6fb0b36..f329e70 100644
--- a/Component/CatalogPriceRules.php
+++ b/Component/CatalogPriceRules.php
@@ -12,9 +12,6 @@
use CtiDigital\Configurator\Api\LoggerInterface;
use Magento\CatalogRule\Api\Data\RuleInterfaceFactory;
-/**
- * Class CatalogPriceRules
- */
class CatalogPriceRules implements ComponentInterface
{
/**
diff --git a/Component/CustomerGroups.php b/Component/CustomerGroups.php
index ef98d58..7023d16 100644
--- a/Component/CustomerGroups.php
+++ b/Component/CustomerGroups.php
@@ -92,12 +92,9 @@ private function createCustomerGroup($groupName, $taxClassId)
->setTaxClassId($taxClassId)
->save();
-
$this->log->logInfo(
sprintf('Customer Group "%s" created', $groupName)
);
-
- return;
}
/**
diff --git a/Component/Sql.php b/Component/Sql.php
index 59168cf..5a83125 100644
--- a/Component/Sql.php
+++ b/Component/Sql.php
@@ -12,7 +12,7 @@
use CtiDigital\Configurator\Component\Processor\SqlSplitProcessor;
/**
- * Class Sql
+ * Class Sql - Runs raw SQL queries - generally a fallback for when a configurator component is not available.
*/
class Sql implements ComponentInterface
{
diff --git a/Component/Websites.php b/Component/Websites.php
index 416d228..a0c8238 100644
--- a/Component/Websites.php
+++ b/Component/Websites.php
@@ -106,7 +106,7 @@ public function execute($data = null)
$indexProcess->load('catalog_product_price');
$indexProcess->reindexAll();
}
- } catch (ComponentException $e) {
+ } catch (\Exception $e) {
$this->log->logError($e->getMessage());
}
}
diff --git a/Console/Command/RunCommand.php b/Console/Command/RunCommand.php
index 7ba8c38..49030df 100644
--- a/Console/Command/RunCommand.php
+++ b/Console/Command/RunCommand.php
@@ -103,7 +103,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
if ($output->getVerbosity() > OutputInterface::VERBOSITY_NORMAL) {
$output->writeln('Finished Configurator');
}
- } catch (ConfiguratorAdapterException $e) {
+ } catch (\Exception $e) {
$output->writeln('' . $e->getMessage() . '');
}
}
diff --git a/Model/Processor.php b/Model/Processor.php
index 3d1c7d9..6b59c78 100644
--- a/Model/Processor.php
+++ b/Model/Processor.php
@@ -13,8 +13,7 @@
use Symfony\Component\Yaml\Yaml;
/**
- * Class Processor
- * @package CtiDigital\Configurator\Model
+ * Class Processor - The overarching class that reads and processes the configurator files.
*
* @SuppressWarnings(PHPMD.ExcessiveClassComplexity)
*/
@@ -454,7 +453,7 @@ private function getData($source)
{
return ($this->isSourceRemote($source) === true) ?
$this->getRemoteData($source) :
- file_get_contents(BP . '/' . $source);
+ file_get_contents(BP . '/' . $source); // phpcs:ignore Magento2.Functions.DiscouragedFunction
}
/**
diff --git a/Test/Integration/ShippingTablesRatesTest.php b/Test/Integration/ShippingTablesRatesTest.php
index c439f89..e94b939 100644
--- a/Test/Integration/ShippingTablesRatesTest.php
+++ b/Test/Integration/ShippingTablesRatesTest.php
@@ -8,8 +8,7 @@
use Magento\Framework\DB\Adapter\AdapterInterface;
/**
- * Class ShippingTablesRatesTest
- * @package CtiDigital\Configurator\Component
+ * Class ShippingTablesRatesTest - Test to run against Shipping Table Rates
* @SuppressWarnings(PHPMD.LongVariable)
*/
class ShippingTablesRatesTest extends \PHPUnit\Framework\TestCase
@@ -33,7 +32,7 @@ class ShippingTablesRatesTest extends \PHPUnit\Framework\TestCase
* From directory_country_region table
* @var array
*/
- private $regionIdMap = array('BER' => 82);
+ private $regionIdMap = ['BER' => 82];
/**
* @var ShippingTableRates