Skip to content

Commit 0bf53de

Browse files
committed
MC-16410: "Whoops, our bad" when copy and paste order information url on storefront
1 parent c2e450f commit 0bf53de

File tree

1 file changed

+4
-5
lines changed
  • app/code/Magento/Sales/Controller/Guest

1 file changed

+4
-5
lines changed

app/code/Magento/Sales/Controller/Guest/View.php

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -53,11 +53,10 @@ public function __construct(
5353
*/
5454
public function execute()
5555
{
56-
if (!$this->getRequest()->isPost()) {
57-
throw new \Magento\Framework\Exception\NotFoundException(__('Page not found.'));
58-
}
59-
if (!$this->formKeyValidator->validate($this->getRequest())) {
60-
return $this->resultRedirectFactory->create()->setPath('*/*/form/');
56+
if ($this->getRequest()->isPost()) {
57+
if (!$this->formKeyValidator->validate($this->getRequest())) {
58+
return $this->resultRedirectFactory->create()->setPath('*/*/form/');
59+
}
6160
}
6261

6362
$result = $this->guestHelper->loadValidOrder($this->getRequest());

0 commit comments

Comments
 (0)