Test Failed
Push — release/5.x ( 3aca7b...4817e3 )
by
unknown
08:19 queued 02:06
created
src/Zicht/Bundle/FrameworkExtraBundle/Form/ParentChoiceType.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
             ->setRequired(array('class'))
47 47
             ->setDefaults(
48 48
                 array(
49
-                    'data_class' => function (Options $o) {
49
+                    'data_class' => function(Options $o) {
50 50
                         return $o->get('class');
51 51
                     },
52 52
                     'required' => false
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
         $doctrine = $this->doctrine;
67 67
 
68 68
         // TODO implement a subscriber for this
69
-        $createParentChoice = function ($parentId) use ($ff, $doctrine, $options) {
69
+        $createParentChoice = function($parentId) use ($ff, $doctrine, $options) {
70 70
             $repo = $doctrine->getRepository($options['class']);
71 71
             $choices = array();
72 72
             if (!$parentId) {
@@ -74,11 +74,11 @@  discard block
 block discarded – undo
74 74
                 $choices[''] = '';
75 75
             } else {
76 76
                 $parent = $repo->find($parentId);
77
-                $choices[$parentId] = '(' . $parent . ')';
77
+                $choices[$parentId] = '('.$parent.')';
78 78
                 $list = $repo->getChildren($parent, true);
79 79
             }
80 80
             foreach ($list as $item) {
81
-                $choices[$item->getId()]= (string)$item;
81
+                $choices[$item->getId()] = (string)$item;
82 82
             }
83 83
             return $ff->createNamed(
84 84
                 'parent',
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
 
91 91
         $builder->addEventListener(
92 92
             FormEvents::PRE_SUBMIT,
93
-            function ($e) use ($ff, $doctrine, $createParentChoice, $options) {
93
+            function($e) use ($ff, $doctrine, $createParentChoice, $options) {
94 94
                 $data     = $e->getData();
95 95
                 $form     = $e->getForm();
96 96
                 $parentId = $data['parent'];
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
 
108 108
         $builder->addEventListener(
109 109
             FormEvents::POST_SET_DATA,
110
-            function (FormEvent $e) use ($ff, $doctrine, $createParentChoice) {
110
+            function(FormEvent $e) use ($ff, $doctrine, $createParentChoice) {
111 111
                 $parentId = null;
112 112
                 if (null !== $e->getData()) {
113 113
                     $selectedItem = $e->getData();
@@ -127,11 +127,11 @@  discard block
 block discarded – undo
127 127
     {
128 128
         parent::finishView($view, $form, $options);
129 129
         $parent = $form->getData();
130
-        $view->vars['parents']= array();
130
+        $view->vars['parents'] = array();
131 131
 
132 132
         if ($parent) {
133 133
             if ($parent->getId()) {
134
-                $view->vars['parents'][]= $parent;
134
+                $view->vars['parents'][] = $parent;
135 135
             }
136 136
             while ($parent = $parent->getParent()) {
137 137
                 // Circular reference break
Please login to merge, or discard this patch.
src/Zicht/Bundle/FrameworkExtraBundle/Doctrine/DoctrineQueryPager.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
     {
71 71
         if (!isset($this->countQuery)) {
72 72
             $c = clone $this->qb;
73
-            $this->countQuery = $c->select('COUNT(' . $this->alias . ') ' . $this->countAlias)->getQuery();
73
+            $this->countQuery = $c->select('COUNT('.$this->alias.') '.$this->countAlias)->getQuery();
74 74
         }
75 75
         return $this->countQuery->getSingleScalarResult();
76 76
     }
Please login to merge, or discard this patch.
src/Zicht/Bundle/FrameworkExtraBundle/Twig/Extension.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -158,7 +158,7 @@  discard block
 block discarded – undo
158 158
     public function prefixMultiple($values, $prefix)
159 159
     {
160 160
         return iter\map(
161
-            function ($value) use ($prefix) {
161
+            function($value) use ($prefix) {
162 162
                 return sprintf('%s%s', $prefix, $value);
163 163
             },
164 164
             $values
@@ -178,7 +178,7 @@  discard block
 block discarded – undo
178 178
     {
179 179
         $translator = $this->translator;
180 180
         return iter\map(
181
-            function ($message) use ($translator, $parameters, $domain, $locale) {
181
+            function($message) use ($translator, $parameters, $domain, $locale) {
182 182
                 return $this->translator->trans($message, $parameters, $domain, $locale);
183 183
             },
184 184
             $messages
@@ -266,7 +266,7 @@  discard block
 block discarded – undo
266 266
             $items->initialize();
267 267
         }
268 268
 
269
-        $whereMethod = $booleanOperator . 'Where';
269
+        $whereMethod = $booleanOperator.'Where';
270 270
 
271 271
         $eb = new ExpressionBuilder();
272 272
         $criteria = new Criteria();
@@ -330,7 +330,7 @@  discard block
 block discarded – undo
330 330
     public function urlStripQuery($url)
331 331
     {
332 332
         $query = parse_url($url, PHP_URL_QUERY);
333
-        return str_replace('?' . $query, '', $url);
333
+        return str_replace('?'.$query, '', $url);
334 334
     }
335 335
 
336 336
     /**
@@ -483,7 +483,7 @@  discard block
 block discarded – undo
483 483
 
484 484
         usort(
485 485
             $collection,
486
-            function ($left, $right) use ($types, $idToIndexMap, $numTypes) {
486
+            function($left, $right) use ($types, $idToIndexMap, $numTypes) {
487 487
                 $localClassNameLeft = Str::classname(get_class($left));
488 488
                 $localClassNameRight = Str::classname(get_class($right));
489 489
 
@@ -617,7 +617,7 @@  discard block
 block discarded – undo
617 617
 
618 618
                 if (null !== $this->translator) {
619 619
                     $message = $this->translator->trans(
620
-                        '%count% ' . $denominator . ' ago',
620
+                        '%count% '.$denominator.' ago',
621 621
                         array('%count%' => $diff->$part)
622 622
                     );
623 623
                 } else {
@@ -655,8 +655,8 @@  discard block
 block discarded – undo
655 655
     {
656 656
         $result = '';
657 657
         foreach (preg_split('/\b/U', $str) as $part) {
658
-            if (strlen($result . $part) > $length) {
659
-                $result = rtrim($result) . $ellipsis;
658
+            if (strlen($result.$part) > $length) {
659
+                $result = rtrim($result).$ellipsis;
660 660
                 break;
661 661
             } else {
662 662
                 $result .= $part;
@@ -731,7 +731,7 @@  discard block
 block discarded – undo
731 731
             parse_str($query, $currentParams);
732 732
             $currentParams += $embedParams;
733 733
 
734
-            return preg_replace('/\?$/', '', $urlOrArray) . '?' . http_build_query($currentParams);
734
+            return preg_replace('/\?$/', '', $urlOrArray).'?'.http_build_query($currentParams);
735 735
         } else {
736 736
             throw new \InvalidArgumentException("Only supports arrays or strings");
737 737
         }
Please login to merge, or discard this patch.
src/Zicht/Bundle/FrameworkExtraBundle/Twig/Meta/AnnotateTokenParser.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -29,12 +29,12 @@
 block discarded – undo
29 29
         $first = $this->parser->getExpressionParser()->parseExpression();
30 30
 
31 31
         if ($stream->test(Twig_Token::BLOCK_END_TYPE)) {
32
-            $info['expr']= $first;
32
+            $info['expr'] = $first;
33 33
         } else {
34
-            $info['name']= $first;
35
-            $info['expr']= $this->parser->getExpressionParser()->parseExpression();
34
+            $info['name'] = $first;
35
+            $info['expr'] = $this->parser->getExpressionParser()->parseExpression();
36 36
             if (!$stream->test(Twig_Token::BLOCK_END_TYPE)) {
37
-                $info['prio']= $this->parser->getExpressionParser()->parseExpression();
37
+                $info['prio'] = $this->parser->getExpressionParser()->parseExpression();
38 38
             }
39 39
         }
40 40
 
Please login to merge, or discard this patch.
src/Zicht/Bundle/FrameworkExtraBundle/Twig/Meta/AnnotateNode.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
     public function compile(Twig_Compiler $compiler)
24 24
     {
25 25
         $has_prio = $this->hasNode('prio');
26
-        $prio = ($has_prio) ? $this->getNode('prio') : 0 ;
26
+        $prio = ($has_prio) ? $this->getNode('prio') : 0;
27 27
         $compiler->addDebugInfo($this);
28 28
         $compiler->write('$this->env->getExtension(\'zicht_framework_extra\')->getAnnotationRegistry()');
29 29
 
@@ -40,6 +40,6 @@  discard block
 block discarded – undo
40 40
             $compiler->subcompile($prio);
41 41
         }
42 42
 
43
-        $compiler->write(');' . "\n");
43
+        $compiler->write(');'."\n");
44 44
     }
45 45
 }
Please login to merge, or discard this patch.
src/Zicht/Bundle/FrameworkExtraBundle/Twig/UglifyGlobal.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
      */
45 45
     public function getSourceFile($file)
46 46
     {
47
-        return ltrim($this->config['src_dir'] . '/' . $file, '/');
47
+        return ltrim($this->config['src_dir'].'/'.$file, '/');
48 48
     }
49 49
 
50 50
 
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
      */
57 57
     public function getTargetFile($file)
58 58
     {
59
-        return ltrim($this->config['target_dir'] . '/' . $file, '/');
59
+        return ltrim($this->config['target_dir'].'/'.$file, '/');
60 60
     }
61 61
 
62 62
 
@@ -88,7 +88,7 @@  discard block
 block discarded – undo
88 88
      */
89 89
     public function offsetSet($offset, $value)
90 90
     {
91
-        throw new \RuntimeException(__CLASS__ . ' is read-only');
91
+        throw new \RuntimeException(__CLASS__.' is read-only');
92 92
     }
93 93
 
94 94
     /**
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
      */
97 97
     public function offsetUnset($offset)
98 98
     {
99
-        throw new \RuntimeException(__CLASS__ . ' is read-only');
99
+        throw new \RuntimeException(__CLASS__.' is read-only');
100 100
     }
101 101
 
102 102
     /**
Please login to merge, or discard this patch.
src/Zicht/Bundle/FrameworkExtraBundle/Twig/ControlStructures/WithNode.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -57,19 +57,19 @@  discard block
 block discarded – undo
57 57
     {
58 58
         $compiler
59 59
             ->addDebugInfo($this)
60
-            ->write('if(!isset($withStack)) {' . "\n")
60
+            ->write('if(!isset($withStack)) {'."\n")
61 61
             ->indent()
62
-            ->write('$withStack = array();' . "\n")
62
+            ->write('$withStack = array();'."\n")
63 63
             ->outdent()
64
-            ->write('}' . "\n")
64
+            ->write('}'."\n")
65 65
             ->write("\n")
66
-            ->write('array_push($withStack, $context);' . "\n");
66
+            ->write('array_push($withStack, $context);'."\n");
67 67
 
68
-        $compiler->write('$values = array_merge(' . "\n")->indent();
68
+        $compiler->write('$values = array_merge('."\n")->indent();
69 69
         $i = 0;
70 70
         foreach ($this->getAttribute('items') as $argument) {
71
-            if ($i ++ > 0) {
72
-                $compiler->raw(',' . "\n");
71
+            if ($i++ > 0) {
72
+                $compiler->raw(','."\n");
73 73
             }
74 74
             $this->compileArgument($compiler, $argument);
75 75
         }
@@ -88,7 +88,7 @@  discard block
 block discarded – undo
88 88
         }
89 89
 
90 90
         if ($this->hasOption('merged')) {
91
-            $compiler->write('$values += $context;' . "\n");
91
+            $compiler->write('$values += $context;'."\n");
92 92
         } else {
93 93
             $compiler->write('$values += array(\'_parent\' => $context);');
94 94
         }
@@ -100,7 +100,7 @@  discard block
 block discarded – undo
100 100
         if (!$this->hasOption('always')) {
101 101
             $compiler->write('}');
102 102
         }
103
-        $compiler->write('$context = array_pop($withStack);' . "\n");
103
+        $compiler->write('$context = array_pop($withStack);'."\n");
104 104
     }
105 105
 
106 106
 
Please login to merge, or discard this patch.
src/Zicht/Bundle/FrameworkExtraBundle/Twig/ControlStructures/StrictNode.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -27,25 +27,25 @@
 block discarded – undo
27 27
     {
28 28
         $compiler
29 29
             ->addDebugInfo($this)
30
-            ->write('$restoreStrict = $this->env->isStrictVariables();' . PHP_EOL)
30
+            ->write('$restoreStrict = $this->env->isStrictVariables();'.PHP_EOL)
31 31
             ->write('$setStrict = (bool)')
32 32
             ->subcompile($this->nodes['expr'])
33 33
             ->write(';');
34 34
 
35 35
         $compiler
36
-            ->write('if ($setStrict) { ' . PHP_EOL)
37
-            ->write('    $this->env->enableStrictVariables();' . PHP_EOL)
38
-            ->write('} else {' . PHP_EOL)
39
-            ->write('    $this->env->disableStrictVariables();' . PHP_EOL)
36
+            ->write('if ($setStrict) { '.PHP_EOL)
37
+            ->write('    $this->env->enableStrictVariables();'.PHP_EOL)
38
+            ->write('} else {'.PHP_EOL)
39
+            ->write('    $this->env->disableStrictVariables();'.PHP_EOL)
40 40
             ->write('}');
41 41
 
42 42
         $compiler->subcompile($this->nodes['body']);
43 43
 
44 44
         $compiler
45
-            ->write('if ($restoreStrict) { ' . PHP_EOL)
46
-            ->write('    $this->env->enableStrictVariables();' . PHP_EOL)
47
-            ->write('} else {' . PHP_EOL)
48
-            ->write('    $this->env->disableStrictVariables();' . PHP_EOL)
45
+            ->write('if ($restoreStrict) { '.PHP_EOL)
46
+            ->write('    $this->env->enableStrictVariables();'.PHP_EOL)
47
+            ->write('} else {'.PHP_EOL)
48
+            ->write('    $this->env->disableStrictVariables();'.PHP_EOL)
49 49
             ->write('}');
50 50
     }
51 51
 }
Please login to merge, or discard this patch.
src/Zicht/Bundle/FrameworkExtraBundle/Util/SortedList.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
     {
42 42
         usort(
43 43
             $this->items,
44
-            function ($a, $b) {
44
+            function($a, $b) {
45 45
                 if ($a[0] === $b[0]) {
46 46
                     return 0;
47 47
                 }
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
     {
58 58
         return new \ArrayIterator(
59 59
             array_map(
60
-                function ($item) {
60
+                function($item) {
61 61
                     return $item[1];
62 62
                 },
63 63
                 $this->items
Please login to merge, or discard this patch.