diff --git a/Octokit.Reactive/Clients/IObservablePullRequestReviewCommentReactionsClient.cs b/Octokit.Reactive/Clients/IObservablePullRequestReviewCommentReactionsClient.cs index 5aace375..a23352ec 100644 --- a/Octokit.Reactive/Clients/IObservablePullRequestReviewCommentReactionsClient.cs +++ b/Octokit.Reactive/Clients/IObservablePullRequestReviewCommentReactionsClient.cs @@ -10,6 +10,16 @@ namespace Octokit.Reactive /// public interface IObservablePullRequestReviewCommentReactionsClient { + /// + /// Get all reactions for a specified Pull Request Review Comment. + /// + /// https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment + /// The owner of the repository + /// The name of the repository + /// The comment id + /// + IObservable GetAll(string owner, string name, int number); + /// /// Creates a reaction for a specified Pull Request Review Comment. /// @@ -20,15 +30,5 @@ namespace Octokit.Reactive /// The reaction to create /// IObservable Create(string owner, string name, int number, NewReaction reaction); - - /// - /// Get all reactions for a specified Pull Request Review Comment. - /// - /// https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment - /// The owner of the repository - /// The name of the repository - /// The comment id - /// - IObservable GetAll(string owner, string name, int number); } } diff --git a/Octokit.Reactive/Clients/ObservablePullRequestReviewCommentReactionsClient.cs b/Octokit.Reactive/Clients/ObservablePullRequestReviewCommentReactionsClient.cs index 29bd3d82..ee528141 100644 --- a/Octokit.Reactive/Clients/ObservablePullRequestReviewCommentReactionsClient.cs +++ b/Octokit.Reactive/Clients/ObservablePullRequestReviewCommentReactionsClient.cs @@ -23,6 +23,22 @@ namespace Octokit.Reactive _connection = client.Connection; } + /// + /// Get all reactions for a specified Pull Request Review Comment. + /// + /// https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment + /// The owner of the repository + /// The name of the repository + /// The comment id + /// + public IObservable GetAll(string owner, string name, int number) + { + Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); + Ensure.ArgumentNotNullOrEmptyString(name, "name"); + + return _connection.GetAndFlattenAllPages(ApiUrls.PullRequestReviewCommentReaction(owner, name, number), null, AcceptHeaders.ReactionsPreview); + } + /// /// Creates a reaction for a specified Pull Request Review Comment. /// @@ -40,21 +56,5 @@ namespace Octokit.Reactive return _client.Create(owner, name, number, reaction).ToObservable(); } - - /// - /// Get all reactions for a specified Pull Request Review Comment. - /// - /// https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment - /// The owner of the repository - /// The name of the repository - /// The comment id - /// - public IObservable GetAll(string owner, string name, int number) - { - Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); - Ensure.ArgumentNotNullOrEmptyString(name, "name"); - - return _connection.GetAndFlattenAllPages(ApiUrls.PullRequestReviewCommentReaction(owner, name, number), null, AcceptHeaders.ReactionsPreview); - } } } diff --git a/Octokit/Clients/PullRequestReviewCommentReactionsClient.cs b/Octokit/Clients/PullRequestReviewCommentReactionsClient.cs index 6cc92088..9da47f71 100644 --- a/Octokit/Clients/PullRequestReviewCommentReactionsClient.cs +++ b/Octokit/Clients/PullRequestReviewCommentReactionsClient.cs @@ -16,6 +16,22 @@ namespace Octokit { } + /// + /// Get all reactions for a specified Pull Request Review Comment. + /// + /// https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment + /// The owner of the repository + /// The name of the repository + /// The comment id + /// + public Task> GetAll(string owner, string name, int number) + { + Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); + Ensure.ArgumentNotNullOrEmptyString(name, "name"); + + return ApiConnection.GetAll(ApiUrls.PullRequestReviewCommentReaction(owner, name, number), AcceptHeaders.ReactionsPreview); + } + /// /// Creates a reaction for a specified Pull Request Review Comment. /// @@ -33,21 +49,5 @@ namespace Octokit return ApiConnection.Post(ApiUrls.PullRequestReviewCommentReaction(owner, name, number), reaction, AcceptHeaders.ReactionsPreview); } - - /// - /// Get all reactions for a specified Pull Request Review Comment. - /// - /// https://developer.github.com/v3/reactions/#list-reactions-for-a-pull-request-review-comment - /// The owner of the repository - /// The name of the repository - /// The comment id - /// - public Task> GetAll(string owner, string name, int number) - { - Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); - Ensure.ArgumentNotNullOrEmptyString(name, "name"); - - return ApiConnection.GetAll(ApiUrls.PullRequestReviewCommentReaction(owner, name, number), AcceptHeaders.ReactionsPreview); - } } }