Blob Blame History Raw
From c53fe24fe8529dd2dd0a989a4a57b49ace2e1a6d Mon Sep 17 00:00:00 2001
From: "Brian J. Murrell" <brian@interlinx.bc.ca>
Date: Tue, 25 Sep 2018 17:31:10 -0400
Subject: [PATCH] Line comments are not posted in create_review()

When create_review() is called with comments in the comments argument,
they are not actually posted in the API call.
---
 github/PullRequest.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/github/PullRequest.py b/github/PullRequest.py
index c855dfb8..688e0625 100644
--- a/github/PullRequest.py
+++ b/github/PullRequest.py
@@ -434,6 +434,8 @@ def create_review(self, commit, body, event=github.GithubObject.NotSet, comments
         post_parameters['event'] = 'COMMENT' if event == github.GithubObject.NotSet else event
         if comments is github.GithubObject.NotSet:
             post_parameters['comments'] = []
+        else:
+            post_parameters['comments'] = comments
         headers, data = self._requester.requestJsonAndCheck(
             "POST",
             self.url + "/reviews",