Merge pull request #155 from webfactory/fix_array_dumper_links
Correctly dump link infopull/152/merge
commit
50d4e0606f
|
@ -28,12 +28,6 @@ class ArrayDumper
|
|||
'extra',
|
||||
'installationSource' => 'installation-source',
|
||||
'license',
|
||||
'requires',
|
||||
'conflicts',
|
||||
'provides',
|
||||
'replaces',
|
||||
'recommends',
|
||||
'suggests',
|
||||
'autoload',
|
||||
'repositories',
|
||||
);
|
||||
|
@ -59,6 +53,14 @@ class ArrayDumper
|
|||
$data['dist']['shasum'] = $package->getDistSha1Checksum();
|
||||
}
|
||||
|
||||
foreach (array('require', 'conflict', 'provide', 'replace', 'suggest', 'recommend') as $linkType) {
|
||||
if ($links = $package->{'get'.ucfirst($linkType).'s'}()) {
|
||||
foreach ($links as $link) {
|
||||
$data[$linkType][$link->getTarget()] = $link->getPrettyConstraint();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
foreach ($keys as $method => $key) {
|
||||
if (is_numeric($method)) {
|
||||
$method = $key;
|
||||
|
|
Loading…
Reference in New Issue