Skip to content

Commit c67a76f

Browse files
committed
Make protected method private
1 parent 49bee81 commit c67a76f

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

app/code/Magento/Checkout/Controller/Cart.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ protected function getBackUrl($defaultUrl = null)
131131
/**
132132
* @return bool
133133
*/
134-
protected function shouldRedirectToCart()
134+
private function shouldRedirectToCart()
135135
{
136136
return $this->_scopeConfig->isSetFlag(
137137
'checkout/cart/redirect_to_cart',

app/code/Magento/Checkout/Controller/Cart/Add.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,4 +205,15 @@ private function getCartUrl()
205205
{
206206
return $this->_url->getUrl('checkout/cart', ['_secure' => true]);
207207
}
208+
209+
/**
210+
* @return bool
211+
*/
212+
private function shouldRedirectToCart()
213+
{
214+
return $this->_scopeConfig->isSetFlag(
215+
'checkout/cart/redirect_to_cart',
216+
\Magento\Store\Model\ScopeInterface::SCOPE_STORE
217+
);
218+
}
208219
}

0 commit comments

Comments
 (0)