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.
2 parents a2a29a3 + 87dbab5 commit c2a2362Copy full SHA for c2a2362
app/code/Magento/OfflineShipping/Model/Carrier/Freeshipping.php
@@ -97,8 +97,18 @@ public function collectRates(RateRequest $request)
97
$method->setCost('0.00');
98
99
$result->append($method);
100
+ } elseif ($this->getConfigData('showmethod')) {
101
+ $error = $this->_rateErrorFactory->create();
102
+ $error->setCarrier($this->_code);
103
+ $error->setCarrierTitle($this->getConfigData('title'));
104
+ $errorMsg = $this->getConfigData('specificerrmsg');
105
+ $error->setErrorMessage(
106
+ $errorMsg ? $errorMsg : __(
107
+ 'Sorry, but we can\'t deliver to the destination country with this shipping module.'
108
+ )
109
+ );
110
+ return $error;
111
}
-
112
return $result;
113
114
0 commit comments