Skip to content

Commit

Permalink
Simplify function signature
Browse files Browse the repository at this point in the history
  • Loading branch information
eli-l committed Oct 19, 2019
1 parent c6ab4d9 commit 104e7f4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Controller/Router.php
Original file line number Diff line number Diff line change
Expand Up @@ -157,17 +157,17 @@ public function match(RequestInterface $request)
protected function getRewrite(RequestInterface $request)
{
$requestPath = $request->getPathInfo();
$storeId = $this->storeManager->getStore()->getId();
return $this->resolveRewrite($requestPath, $storeId);
return $this->resolveRewrite($requestPath);
}

/**
* @param string $requestPath
* @param $storeId
* @return UrlRewrite|null
*/
protected function resolveRewrite(string $requestPath, int $storeId)
protected function resolveRewrite(string $requestPath)
{
$storeId = $this->storeManager->getStore()->getId();
return $this->urlFinder->findOneByData([
UrlRewrite::REQUEST_PATH => ltrim($requestPath, '/'),
UrlRewrite::STORE_ID => $storeId
Expand Down

0 comments on commit 104e7f4

Please sign in to comment.