listSingleCommitComments method

Stream<CommitComment> listSingleCommitComments(
  1. RepositorySlug slug,
  2. RepositoryCommit commit
)

Returns a list of all comments for a specific commit.

https://developer.github.com/v3/repos/comments/#list-comments-for-a-single-commit

Implementation

Stream<CommitComment> listSingleCommitComments(
  RepositorySlug slug,
  RepositoryCommit commit,
) {
  ArgumentError.checkNotNull(slug);
  ArgumentError.checkNotNull(commit);
  return PaginationHelper(github)
      .objects<Map<String, dynamic>, CommitComment>(
    'GET',
    '/repos/${slug.fullName}/commits/${commit.sha}/comments',
    (i) => CommitComment.fromJson(i),
    statusCode: StatusCodes.OK,
  );
}