Skip to content

Commit

Permalink
Fixing composer excludes.
Browse files Browse the repository at this point in the history
  • Loading branch information
grasmash committed Oct 17, 2016
1 parent 87f6cda commit 687d14f
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/Console/Command/ComposerMungeCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,14 @@ protected function munge($file1, $file2) {
}
// Skip merging entirely if '*' is excluded.
if ($exclude_keys == '*') {
return $file1_contents;
$output = $file1_contents;
}
else {
$output = $this->mergeKeyed($file1_contents, $file2_contents, $exclude_keys);

$output = $this->mergeKeyed($file1_contents, $file2_contents, $exclude_keys);

if (empty($exclude_keys['repositories'])) {
$output['repositories'] = $this->mergeRepositories((array) $file1_contents['repositories'], (array) $file2_contents['repositories']);
if (empty($exclude_keys['repositories'])) {
$output['repositories'] = $this->mergeRepositories((array) $file1_contents['repositories'], (array) $file2_contents['repositories']);
}
}

$output_json = json_encode($output, JSON_PRETTY_PRINT|JSON_UNESCAPED_SLASHES);
Expand Down

0 comments on commit 687d14f

Please sign in to comment.