Skip to content

Commit

Permalink
Use named parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
stefanzweifel committed May 18, 2024
1 parent 3863498 commit 185bab7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/Actions/PlaceReleaseNotesAtTheTopAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function execute(Document $changelog, string $headingText, string $releas
// Find the Heading of the previous Version
$previousVersionHeading = $this->findFirstSecondLevelHeading->find($changelog);

// If the previous version heading contains a compare URL, we should use that to generate the new release heading
// If the previous version heading contains a URL, we should use that to generate the new release heading
// If the previous version does not contain a URL, don't add a URL to the new release heading
if ($previousVersionHeading && $this->headingContainsLink($previousVersionHeading)) {

Expand All @@ -51,7 +51,7 @@ public function execute(Document $changelog, string $headingText, string $releas
$this->gitHubActionsOutput->add('UNRELEASED_COMPARE_URL', $updatedUrl);

// Create new Heading containing the new version number
$newReleaseHeading = $this->createNewReleaseHeadingWithCompareUrl->create($repositoryUrl, $previousVersion, $headingText, $headingText, $releaseDate, $hideDate);
$newReleaseHeading = $this->createNewReleaseHeadingWithCompareUrl->create(repositoryUrl: $repositoryUrl, previousVersion: $previousVersion, latestVersion: $headingText, headingText: $headingText, releaseDate: $releaseDate, hideDate: $hideDate);
} else {
$newReleaseHeading = $this->createNewReleaseHeading->create($headingText, $releaseDate, $hideDate);
}
Expand Down

0 comments on commit 185bab7

Please sign in to comment.