Skip to content

Commit 827c537

Browse files
authored
Issue #2033: made code clearer on using number in some methods (#2034)
1 parent 5d3344a commit 827c537

File tree

1 file changed

+11
-8
lines changed

1 file changed

+11
-8
lines changed

src/main/java/org/kohsuke/github/GHRepository.java

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -349,14 +349,14 @@ public GHUser getOwner() throws IOException {
349349
/**
350350
* Gets issue.
351351
*
352-
* @param id
353-
* the id
352+
* @param number
353+
* the number of the issue
354354
* @return the issue
355355
* @throws IOException
356356
* the io exception
357357
*/
358-
public GHIssue getIssue(int id) throws IOException {
359-
return root().createRequest().withUrlPath(getApiTailUrl("issues/" + id)).fetch(GHIssue.class).wrap(this);
358+
public GHIssue getIssue(int number) throws IOException {
359+
return root().createRequest().withUrlPath(getApiTailUrl("issues/" + number)).fetch(GHIssue.class).wrap(this);
360360
}
361361

362362
/**
@@ -1500,14 +1500,17 @@ public GHRepository forkTo(GHOrganization org) throws IOException {
15001500
/**
15011501
* Retrieves a specified pull request.
15021502
*
1503-
* @param i
1504-
* the
1503+
* @param number
1504+
* the number of the pull request
15051505
* @return the pull request
15061506
* @throws IOException
15071507
* the io exception
15081508
*/
1509-
public GHPullRequest getPullRequest(int i) throws IOException {
1510-
return root().createRequest().withUrlPath(getApiTailUrl("pulls/" + i)).fetch(GHPullRequest.class).wrapUp(this);
1509+
public GHPullRequest getPullRequest(int number) throws IOException {
1510+
return root().createRequest()
1511+
.withUrlPath(getApiTailUrl("pulls/" + number))
1512+
.fetch(GHPullRequest.class)
1513+
.wrapUp(this);
15111514
}
15121515

15131516
/**

0 commit comments

Comments
 (0)