From 167b0f46ef946fad3ca13976c3b87598f505e2ea Mon Sep 17 00:00:00 2001 From: Bo-Yi Wu Date: Mon, 15 Mar 2021 02:52:12 +0800 Subject: chore(models): rewrite code format. (#14754) * chore: rewrite format. * chore: update format Signed-off-by: Bo-Yi Wu * chore: update format Signed-off-by: Bo-Yi Wu * chore: Adjacent parameters with the same type should be grouped together * chore: update format. --- models/pull.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'models/pull.go') diff --git a/models/pull.go b/models/pull.go index 7dacf6a8d7..47e699e192 100644 --- a/models/pull.go +++ b/models/pull.go @@ -241,7 +241,6 @@ func (pr *PullRequest) getApprovalCounts(e Engine) ([]*ReviewCount, error) { // GetApprovers returns the approvers of the pull request func (pr *PullRequest) GetApprovers() string { - stringBuilder := strings.Builder{} if err := pr.getReviewedByLines(&stringBuilder); err != nil { log.Error("Unable to getReviewedByLines: Error: %v", err) @@ -504,7 +503,7 @@ func GetLatestPullRequestByHeadInfo(repoID int64, branch string) (*PullRequest, } // GetPullRequestByIndex returns a pull request by the given index -func GetPullRequestByIndex(repoID int64, index int64) (*PullRequest, error) { +func GetPullRequestByIndex(repoID, index int64) (*PullRequest, error) { pr := &PullRequest{ BaseRepoID: repoID, Index: index, -- cgit v1.2.3