We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8dfe26a commit 1fde486Copy full SHA for 1fde486
app/code/Magento/Cms/Helper/Page.php
@@ -180,14 +180,15 @@ public function prepareResultPage(Action $action, $pageId = null)
180
/**
181
* Retrieve page direct URL
182
*
183
- * @param string $pageId
184
- * @return string
+ * @param null $pageId
+ * @return string|null
185
+ * @throws \Magento\Framework\Exception\NoSuchEntityException
186
*/
187
public function getPageUrl($pageId = null)
188
{
189
/** @var \Magento\Cms\Model\Page $page */
190
$page = $this->_pageFactory->create();
- if ($pageId !== null && $pageId !== $page->getId()) {
191
+ if ($pageId !== null) {
192
$page->setStoreId($this->_storeManager->getStore()->getId());
193
$page->load($pageId);
194
}
0 commit comments