protected function _rewriteConfig() { $h = Mage::helper('gomage_checkout'); if ($h->getConfigData('general/enabled')) { $requestPath = trim($this->_request->getPathInfo(), '/'); if ($requestPath == 'checkout/onepage' || $requestPath == 'checkout/onepage/index') { if (in_array(Mage::app()->getStore()->getWebsiteId(), $h->getAvailavelWebsites())) { if (!($h->isMobileDevice() && (bool) $h->getConfigData('general/disable_mobile'))) { $request->setPathInfo('gomage_checkout/onepage'); return true; } } } } return parent::_rewriteConfig(); }