Skip to content

Commit

Permalink
[BUGFIX] Context CGL issues and relocate condition view helpers
Browse files Browse the repository at this point in the history
  • Loading branch information
BenjaminBeck committed Dec 10, 2014
1 parent f042f4b commit 982020c
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
namespace FluidTYPO3\Vhs\ViewHelpers\Context;
namespace FluidTYPO3\Vhs\ViewHelpers\Condition\Context;

/***************************************************************
* Copyright notice
Expand All @@ -18,6 +18,7 @@
* GNU General Public License for more details.
* This copyright notice MUST APPEAR in all copies of the script!
* ************************************************************* */

use TYPO3\CMS\Fluid\Core\ViewHelper\AbstractConditionViewHelper;
use TYPO3\CMS\Core\Utility\GeneralUtility;

Expand All @@ -36,7 +37,7 @@
*
* @author Benjamin Beck <[email protected]>
* @package Vhs
* @subpackage ViewHelpers\Context
* @subpackage ViewHelpers\Condition\Context
*/
class IsDevelopmentViewHelper extends AbstractConditionViewHelper {

Expand All @@ -46,7 +47,7 @@ class IsDevelopmentViewHelper extends AbstractConditionViewHelper {
* @return string
*/
public function render () {
if ( TRUE === $this->isDevelopmentContext() ) {
if (TRUE === $this->isDevelopmentContext()) {
return $this->renderThenChild();
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
namespace FluidTYPO3\Vhs\ViewHelpers\Context;
namespace FluidTYPO3\Vhs\ViewHelpers\Condition\Context;

/***************************************************************
* Copyright notice
Expand All @@ -18,6 +18,7 @@
* GNU General Public License for more details.
* This copyright notice MUST APPEAR in all copies of the script!
* ************************************************************* */

use TYPO3\CMS\Fluid\Core\ViewHelper\AbstractConditionViewHelper;
use TYPO3\CMS\Core\Utility\GeneralUtility;

Expand All @@ -36,7 +37,7 @@
*
* @author Benjamin Beck <[email protected]>
* @package Vhs
* @subpackage ViewHelpers\Context
* @subpackage ViewHelpers\Condition\Context
*/
class IsProductionViewHelper extends AbstractConditionViewHelper {

Expand All @@ -46,7 +47,7 @@ class IsProductionViewHelper extends AbstractConditionViewHelper {
* @return string
*/
public function render () {
if ( TRUE === $this->isProductionContext() ) {
if (TRUE === $this->isProductionContext()) {
return $this->renderThenChild();
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php
namespace FluidTYPO3\Vhs\ViewHelpers\Context;
namespace FluidTYPO3\Vhs\ViewHelpers\Condition\Context;

/***************************************************************
* Copyright notice
Expand All @@ -18,6 +18,7 @@
* GNU General Public License for more details.
* This copyright notice MUST APPEAR in all copies of the script!
* ************************************************************* */

use TYPO3\CMS\Fluid\Core\ViewHelper\AbstractConditionViewHelper;
use TYPO3\CMS\Core\Utility\GeneralUtility;

Expand All @@ -36,7 +37,7 @@
*
* @author Benjamin Beck <[email protected]>
* @package Vhs
* @subpackage ViewHelpers\Context
* @subpackage ViewHelpers\Condition\Context
*/
class IsTestingViewHelper extends AbstractConditionViewHelper {

Expand All @@ -46,7 +47,7 @@ class IsTestingViewHelper extends AbstractConditionViewHelper {
* @return string
*/
public function render () {
if ( TRUE === $this->isTestingContext() ) {
if (TRUE === $this->isTestingContext()) {
return $this->renderThenChild();
}

Expand Down
3 changes: 3 additions & 0 deletions Classes/ViewHelpers/Context/GetViewHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
* GNU General Public License for more details.
* This copyright notice MUST APPEAR in all copies of the script!
* ************************************************************* */

use TYPO3\CMS\Fluid\Core\ViewHelper\AbstractViewHelper;
use TYPO3\CMS\Core\Utility\GeneralUtility;

Expand All @@ -26,6 +27,8 @@
*
* Returns the full application context which may include possible sub-contexts.
* If no application context has been set, then the default context is production.
* TYPO3 provides three built-in contexts: 'Production', 'Development' and 'Testing'.
* Each context can be extended with sub-contexts like: 'Production/Staging' or ' Production/Staging/Server1'
*
* #### Note about how to set the application context
*
Expand Down

0 comments on commit 982020c

Please sign in to comment.