Skip to content

Commit

Permalink
PSR2 fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
sreichel committed Jun 23, 2019
1 parent d138572 commit f366ff8
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,4 @@ class Mage_Contacts_Model_System_Config_Backend_Links extends Mage_Adminhtml_Mod
* @var array
*/
protected $_cacheTags = array(Mage_Core_Model_Store::CACHE_TAG, Mage_Cms_Model_Block::CACHE_TAG);

}
12 changes: 5 additions & 7 deletions app/code/core/Mage/Contacts/controllers/IndexController.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public function preDispatch()
{
parent::preDispatch();

if( !Mage::getStoreConfigFlag(self::XML_PATH_ENABLED) ) {
if (!Mage::getStoreConfigFlag(self::XML_PATH_ENABLED)) {
$this->norouteAction();
}
}
Expand All @@ -54,7 +54,7 @@ public function indexAction()
{
$this->loadLayout();
$this->getLayout()->getBlock('contactForm')
->setFormAction( Mage::getUrl('*/*/post', array('_secure' => $this->getRequest()->isSecure())) );
->setFormAction(Mage::getUrl('*/*/post', array('_secure' => $this->getRequest()->isSecure())));

$this->_initLayoutMessages('customer/session');
$this->_initLayoutMessages('catalog/session');
Expand All @@ -64,7 +64,7 @@ public function indexAction()
public function postAction()
{
$post = $this->getRequest()->getPost();
if ( $post ) {
if ($post) {
$translate = Mage::getSingleton('core/translate');
/* @var Mage_Core_Model_Translate $translate */
$translate->setTranslateInline(false);
Expand All @@ -74,11 +74,11 @@ public function postAction()

$error = false;

if (!Zend_Validate::is(trim($post['name']) , 'NotEmpty')) {
if (!Zend_Validate::is(trim($post['name']), 'NotEmpty')) {
$error = true;
}

if (!Zend_Validate::is(trim($post['comment']) , 'NotEmpty')) {
if (!Zend_Validate::is(trim($post['comment']), 'NotEmpty')) {
$error = true;
}

Expand Down Expand Up @@ -122,10 +122,8 @@ public function postAction()
$this->_redirect('*/*/');
return;
}

} else {
$this->_redirect('*/*/');
}
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,3 @@
/* @var Mage_Core_Model_Resource_Setup $installer */

$installer = $this;

0 comments on commit f366ff8

Please sign in to comment.