Completed
Push — develop ( 88dc2a...0bfa91 )
by
unknown
09:36
created
module/Core/src/Core/Form/View/Helper/ToggleButton.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
             if (null === $buttonContent) {
29 29
                 throw new Exception\DomainException(
30 30
                     sprintf(
31
-                        '%s expects either button content as the second argument, ' .
31
+                        '%s expects either button content as the second argument, '.
32 32
                         'or that the element provided has a label value; neither found',
33 33
                         __METHOD__
34 34
                     )
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
         $checkedBoole   = ($value == 1 || $value == 'on');
52 52
         
53 53
         //$checked        = $checkedBoole?'checked="checked"':'';
54
-        $checkedClass   = $checkedBoole?'active"':'';
54
+        $checkedClass   = $checkedBoole ? 'active"' : '';
55 55
 
56 56
         $hiddenElement = '';
57 57
         if ($element->useHiddenElement()) {
@@ -68,11 +68,11 @@  discard block
 block discarded – undo
68 68
             $element->setUseHiddenElement(false);
69 69
         }
70 70
 
71
-        $buttonContent = $hiddenElement . PHP_EOL
72
-                . '<div class="btn-group" data-toggle="buttons">' . PHP_EOL
73
-                . '<label class="btn btn-default ' . $checkedClass . '">' . PHP_EOL
74
-                . parent::render($element) . $buttonContent . PHP_EOL . '</label>' . PHP_EOL
75
-                . '</div>' . PHP_EOL;
71
+        $buttonContent = $hiddenElement.PHP_EOL
72
+                . '<div class="btn-group" data-toggle="buttons">'.PHP_EOL
73
+                . '<label class="btn btn-default '.$checkedClass.'">'.PHP_EOL
74
+                . parent::render($element).$buttonContent.PHP_EOL.'</label>'.PHP_EOL
75
+                . '</div>'.PHP_EOL;
76 76
         
77 77
         //$buttonContent = '<div><div class="processing yk-hidden"><span class="fa-spin yk-icon-spinner yk-icon"></span> ' .
78 78
         //    $translator->translate('processing', $this->getTranslatorTextDomain()) . '</div><div class="default">' . $escape($buttonContent) . '</div></div>';
Please login to merge, or discard this patch.