Explorar el Código

Use {}for foreach

Matthias Pigulla hace 13 años
padre
commit
737fe32f4d
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      src/Composer/Package/Dumper/ArrayDumper.php

+ 2 - 1
src/Composer/Package/Dumper/ArrayDumper.php

@@ -55,8 +55,9 @@ class ArrayDumper
 
 
         foreach (array('require', 'conflict', 'provide', 'replace', 'suggest', 'recommend') as $linkType) {
         foreach (array('require', 'conflict', 'provide', 'replace', 'suggest', 'recommend') as $linkType) {
             if ($links = $package->{'get'.ucfirst($linkType).'s'}()) {
             if ($links = $package->{'get'.ucfirst($linkType).'s'}()) {
-                foreach ($links as $link)
+                foreach ($links as $link) {
                     $data[$linkType][$link->getTarget()] = $link->getPrettyConstraint();
                     $data[$linkType][$link->getTarget()] = $link->getPrettyConstraint();
+                }
             }
             }
         }
         }