Skip to content

Commit

Permalink
Update Template.php
Browse files Browse the repository at this point in the history
To exclude Warning:

Warning: include(): Filename cannot be empty  in /magento/.modman/Cm_Diehard/Mage/Core/Block/Template.php on line 250

#0 /magento/.modman/Cm_Diehard/Mage/Core/Block/Template.php(250): mageCoreErrorHandler(2, 'include(): File...', '/var/www/lightt...', 250, Array)
colinmollenhour#1 /magento/.modman/Cm_Diehard/Mage/Core/Block/Template.php(250): include()
colinmollenhour#2 /magento/.modman/Cm_Diehard/Mage/Core/Block/Template.php(281): Mage_Core_Block_Template->fetchView('adminhtml/base/...')
colinmollenhour#3 /magento/.modman/Cm_Diehard/Mage/Core/Block/Template.php(295): Mage_Core_Block_Template->renderView()
colinmollenhour#4 /magento/app/code/core/Mage/Adminhtml/Block/Template.php(81): Mage_Core_Block_Template->_toHtml()
colinmollenhour#5 /magento/.modman/Cm_Diehard/Mage/Core/Block/Abstract.php(936): Mage_Adminhtml_Block_Template->_toHtml()
colinmollenhour#6 /magento/app/code/core/Mage/Core/Block/Text/List.php(43): Mage_Core_Block_Abstract->toHtml()
colinmollenhour#7 /magento/.modman/Cm_Diehard/Mage/Core/Block/Abstract.php(936): Mage_Core_Block_Text_List->_toHtml()
colinmollenhour#8 /magento/.modman/Cm_Diehard/Mage/Core/Block/Abstract.php(642): Mage_Core_Block_Abstract->toHtml()
colinmollenhour#9 /magento/.modman/Cm_Diehard/Mage/Core/Block/Abstract.php(586): Mage_Core_Block_Abstract->_getChildHtml('content', true)
colinmollenhour#10 /magento/app/design/adminhtml/default/default/template/page.phtml(67): Mage_Core_Block_Abstract->getChildHtml('content')
colinmollenhour#11 /magento/.modman/Cm_Diehard/Mage/Core/Block/Template.php(250): include('/var/www/lightt...')
colinmollenhour#12 /magento/.modman/Cm_Diehard/Mage/Core/Block/Template.php(281): Mage_Core_Block_Template->fetchView('adminhtml/defau...')
colinmollenhour#13 /magento/.modman/Cm_Diehard/Mage/Core/Block/Template.php(295): Mage_Core_Block_Template->renderView()
colinmollenhour#14 /magento/app/code/core/Mage/Adminhtml/Block/Template.php(81): Mage_Core_Block_Template->_toHtml()
colinmollenhour#15 /magento/.modman/Cm_Diehard/Mage/Core/Block/Abstract.php(936): Mage_Adminhtml_Block_Template->_toHtml()
colinmollenhour#16 /magento/app/code/core/Mage/Core/Model/Layout.php(556): Mage_Core_Block_Abstract->toHtml()
colinmollenhour#17 /magento/app/code/core/Mage/Core/Controller/Varien/Action.php(390): Mage_Core_Model_Layout->getOutput()
colinmollenhour#18 /magento/app/code/core/Mage/Adminhtml/controllers/System/ConfigController.php(119): Mage_Core_Controller_Varien_Action->renderLayout()
colinmollenhour#19 /magento/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Adminhtml_System_ConfigController->editAction()
colinmollenhour#20 /magento/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('edit')
colinmollenhour#21 /magento/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
colinmollenhour#22 /magento/app/code/core/Mage/Core/Model/App.php(365): Mage_Core_Controller_Varien_Front->dispatch()
colinmollenhour#23 /magento/app/Mage.php(683): Mage_Core_Model_App->run(Array)
colinmollenhour#24 /magento/pub/index.php(366): Mage::run('default', 'store')
colinmollenhour#25 {main}
  • Loading branch information
coresh committed Sep 1, 2015
1 parent 8d0e3e6 commit acd83da
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Mage/Core/Block/Template.php
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ public function fetchView($fileName)

try {
$includeFilePath = realpath($this->_viewDir . DS . $fileName);
if (strpos($includeFilePath, realpath($this->_viewDir)) === 0 || $this->_getAllowSymlinks()) {
if (file_exists($includeFilePath) && (strpos($includeFilePath, realpath($this->_viewDir)) === 0 || $this->_getAllowSymlinks())) {
include $includeFilePath;
} else {
Mage::log('Not valid template file:'.$fileName, Zend_Log::CRIT, null, null, true);
Expand Down

0 comments on commit acd83da

Please sign in to comment.