Skip to content

Commit

Permalink
BEG-160 | CS fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanjehan-aligent committed Apr 11, 2024
1 parent f99bf48 commit b4bcf59
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 14 deletions.
7 changes: 7 additions & 0 deletions Api/PrerenderClientInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,12 @@

interface PrerenderClientInterface
{
/**
* Call Prerender service API to recache list of URLs
*
* @param array $urls
* @param int $storeId
* @return void
*/
public function recacheUrls(array $urls, int $storeId): void;
}
8 changes: 1 addition & 7 deletions Model/Url/GetUrlsForCategories.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
use Magento\Catalog\Model\Category;
use Magento\Catalog\Model\ResourceModel\Category\CollectionFactory;
use Magento\Framework\Exception\NoSuchEntityException;
use Magento\Framework\Url;
use Magento\Store\Model\App\Emulation;
use Magento\Store\Model\Store;
use Magento\Store\Model\StoreManagerInterface;
Expand All @@ -25,9 +24,6 @@ class GetUrlsForCategories
/** @var Emulation */
private Emulation $emulation;

/** @var Url */
private Url $url;

/**
*
* @param CollectionFactory $categoryCollectionFactory
Expand All @@ -37,13 +33,11 @@ class GetUrlsForCategories
public function __construct(
CollectionFactory $categoryCollectionFactory,
StoreManagerInterface $storeManager,
Emulation $emulation,
Url $url
Emulation $emulation
) {
$this->categoryCollectionFactory = $categoryCollectionFactory;
$this->storeManager = $storeManager;
$this->emulation = $emulation;
$this->url = $url;
}

/**
Expand Down
9 changes: 2 additions & 7 deletions Model/Url/GetUrlsForProducts.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
*/

declare(strict_types=1);

namespace Aligent\Prerender\Model\Url;

use Magento\Catalog\Model\Product;
use Magento\Catalog\Model\ResourceModel\Product\CollectionFactory;
use Magento\Framework\Exception\NoSuchEntityException;
use Magento\Framework\Url;
use Magento\Store\Model\App\Emulation;
use Magento\Store\Model\Store;
use Magento\Store\Model\StoreManagerInterface;
Expand All @@ -25,9 +25,6 @@ class GetUrlsForProducts
/** @var Emulation */
private Emulation $emulation;

/** @var Url */
private Url $url;

/**
*
* @param CollectionFactory $productCollectionFactory
Expand All @@ -37,13 +34,11 @@ class GetUrlsForProducts
public function __construct(
CollectionFactory $productCollectionFactory,
StoreManagerInterface $storeManager,
Emulation $emulation,
Url $url
Emulation $emulation
) {
$this->productCollectionFactory = $productCollectionFactory;
$this->storeManager = $storeManager;
$this->emulation = $emulation;
$this->url = $url;
}

/**
Expand Down

0 comments on commit b4bcf59

Please sign in to comment.