Completed
Push — master ( a610d6...977b27 )
by Vitaliy
02:36
created
src/Form.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -188,7 +188,7 @@  discard block
 block discarded – undo
188 188
      */
189 189
     protected function addError($error) {
190 190
       if (!is_string($error)) {
191
-        throw new \InvalidArgumentException('Error should be a string, ' . gettype($error) . ' given.');
191
+        throw new \InvalidArgumentException('Error should be a string, '.gettype($error).' given.');
192 192
       }
193 193
       $this->validationResult = false;
194 194
       $this->errorList[] = $error;
@@ -235,7 +235,7 @@  discard block
 block discarded – undo
235 235
      */
236 236
     public function getElement($name) {
237 237
       if (empty($this->elements[$name])) {
238
-        throw new \InvalidArgumentException('Element with name "' . $name . '" not found');
238
+        throw new \InvalidArgumentException('Element with name "'.$name.'" not found');
239 239
       }
240 240
       return $this->elements[$name];
241 241
     }
@@ -397,7 +397,7 @@  discard block
 block discarded – undo
397 397
      */
398 398
     public function addElement(Element\BaseElement $element) {
399 399
       if (isset($this->elements[$element->getName()])) {
400
-        throw new \Exception('Element with name ' . $element->getName() . ' is already added. Use setElement to overwrite it or change name');
400
+        throw new \Exception('Element with name '.$element->getName().' is already added. Use setElement to overwrite it or change name');
401 401
       }
402 402
 
403 403
       $this->cleanValidationFlag();
@@ -412,7 +412,7 @@  discard block
 block discarded – undo
412 412
      * @return string
413 413
      */
414 414
     public function render() {
415
-      return $this->renderStart() . $this->renderElements() . $this->renderEnd();
415
+      return $this->renderStart().$this->renderElements().$this->renderEnd();
416 416
     }
417 417
 
418 418
 
@@ -431,8 +431,8 @@  discard block
 block discarded – undo
431 431
         }
432 432
 
433 433
         $formHtml .=
434
-          '<dt>' . $element->getText() . '</dt>' .
435
-          '<dd>' . $element->render() . '</dd>';
434
+          '<dt>'.$element->getText().'</dt>'.
435
+          '<dd>'.$element->render().'</dd>';
436 436
       }
437 437
 
438 438
       $formHtml .= '</dl>';
@@ -456,7 +456,7 @@  discard block
 block discarded – undo
456 456
       $method = $this->getMethod();
457 457
       $this->setAttribute('method', $method);
458 458
 
459
-      $html = '<form ' . Element\Html::renderAttributes($this->getAttributes()) . '>';
459
+      $html = '<form '.Element\Html::renderAttributes($this->getAttributes()).'>';
460 460
       $html .= $hidden->render();
461 461
 
462 462
       # render hidden element
Please login to merge, or discard this patch.
Tests/Filters/CallbackFilterTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
 
13 13
     public function testCustomFilter() {
14 14
 
15
-      $filter = new CallbackFilter(function ($value) {
15
+      $filter = new CallbackFilter(function($value) {
16 16
         $value = str_replace(' ', '-', $value);
17 17
         $value = trim($value, '-');
18 18
         return $value;
Please login to merge, or discard this patch.