[FOLLOWUP][TASK] Move arguments to initializeArguments() in CshVH 93/49093/2
authorMarkus Friedrich <markus.friedrich@dkd.de>
Tue, 19 Jul 2016 11:34:41 +0000 (13:34 +0200)
committerNicole Cordes <typo3@cordes.co>
Tue, 19 Jul 2016 11:53:29 +0000 (13:53 +0200)
Patch adds missing parent::initializeArguments() call and removes
unneeded variable initializations

Resolves: #77128
Releases: master
Change-Id: If3ec88ccd7b73ab39544bc710823377af8ded128
Reviewed-on: https://review.typo3.org/49093
Reviewed-by: Johannes Bernhard Goslar <johannes.goslar@dkd.de>
Tested-by: Johannes Bernhard Goslar <johannes.goslar@dkd.de>
Tested-by: Bamboo TYPO3com <info@typo3.com>
Reviewed-by: Steven Cardoso <steven.cardoso@dkd.de>
Tested-by: Steven Cardoso <steven.cardoso@dkd.de>
Reviewed-by: Nicole Cordes <typo3@cordes.co>
Tested-by: Nicole Cordes <typo3@cordes.co>
typo3/sysext/fluid/Classes/ViewHelpers/Be/Buttons/CshViewHelper.php

index 3174241..6cd6a52 100644 (file)
@@ -52,11 +52,11 @@ class CshViewHelper extends AbstractBackendViewHelper
     /**
      * Initialize arguments.
      *
-     * @api
      * @throws \TYPO3Fluid\Fluid\Core\ViewHelper\Exception
      */
     public function initializeArguments()
     {
+        parent::initializeArguments();
         $this->registerArgument('table', 'string', 'Table name (\'_MOD_\'+module name). If not set, the current module name will be used');
         $this->registerArgument('field', 'string', 'Field name (CSH locallang main key)', false, '');
         $this->registerArgument('wrap', 'string', 'Markup to wrap around the CSH, split by "|"', false, '');
@@ -69,16 +69,8 @@ class CshViewHelper extends AbstractBackendViewHelper
      */
     public function render()
     {
-        $table = $this->arguments['table'];
-        $field = $this->arguments['field'];
-        $wrap = $this->arguments['wrap'];
-
         return static::renderStatic(
-            array(
-                'table' => $table,
-                'field' => $field,
-                'wrap' => $wrap
-            ),
+            $this->arguments,
             $this->buildRenderChildrenClosure(),
             $this->renderingContext
         );