Skip to content

Commit

Permalink
Fix parsing of comments in arrays of sponsor info, fixes composer/pac…
Browse files Browse the repository at this point in the history
  • Loading branch information
Seldaek committed Oct 28, 2024
1 parent e0ed22b commit e02f7ba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Composer/Repository/Vcs/GitHubDriver.php
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ private function getFundingInfo()
$key = $match[1];
continue;
}
if (Preg::isMatchStrictGroups('{^\[(.*)\](?:\s*#.*)?$}', $match[2], $match2)) {
if (Preg::isMatchStrictGroups('{^\[(.*?)\](?:\s*#.*)?$}', $match[2], $match2)) {
foreach (array_map('trim', Preg::split('{[\'"]?\s*,\s*[\'"]?}', $match2[1])) as $item) {
$result[] = ['type' => $match[1], 'url' => trim($item, '"\' ')];
}
Expand Down

0 comments on commit e02f7ba

Please sign in to comment.