From 5a957eb91a0263e166abf1a037bb66b9f2743353 Mon Sep 17 00:00:00 2001 From: Vincent Langlet Date: Sun, 9 May 2021 00:34:01 +0200 Subject: [PATCH] Rename branchLatest --- src/Action/DetermineNextRelease.php | 2 +- src/Github/Api/Releases.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Action/DetermineNextRelease.php b/src/Action/DetermineNextRelease.php index b2ddfdfce..c3538f220 100644 --- a/src/Action/DetermineNextRelease.php +++ b/src/Action/DetermineNextRelease.php @@ -54,7 +54,7 @@ public function __invoke(Project $project, Branch $branch): NextRelease $repository = $project->repository(); try { - $currentRelease = $this->releases->branchLatest($repository, $branch); + $currentRelease = $this->releases->latestForBranch($repository, $branch); } catch (LatestReleaseNotFound $e) { throw CannotDetermineNextRelease::forBranch( $project, diff --git a/src/Github/Api/Releases.php b/src/Github/Api/Releases.php index 6c27df588..47a36ee0a 100644 --- a/src/Github/Api/Releases.php +++ b/src/Github/Api/Releases.php @@ -49,7 +49,7 @@ public function latest(Repository $repository): Release return Release::fromResponse($response); } - public function branchLatest(Repository $repository, Branch $branch): Release + public function latestForBranch(Repository $repository, Branch $branch): Release { try { $response = $this->github->repo()->releases()->all(