* Fetch a single pull request review in the given repository
(
owner: string,
name: string,
prNumber: string,
reviewId: string
)
| 1282 | * Fetch a single pull request review in the given repository |
| 1283 | */ |
| 1284 | public async fetchPullRequestReview( |
| 1285 | owner: string, |
| 1286 | name: string, |
| 1287 | prNumber: string, |
| 1288 | reviewId: string |
| 1289 | ) { |
| 1290 | try { |
| 1291 | const path = `/repos/${owner}/${name}/pulls/${prNumber}/reviews/${reviewId}` |
| 1292 | const response = await this.ghRequest('GET', path) |
| 1293 | return await parsedResponse<IAPIPullRequestReview>(response) |
| 1294 | } catch (e) { |
| 1295 | log.debug( |
| 1296 | `failed fetching PR review ${reviewId} for ${owner}/${name}/pulls/${prNumber}`, |
| 1297 | e |
| 1298 | ) |
| 1299 | return null |
| 1300 | } |
| 1301 | } |
| 1302 | |
| 1303 | /** Fetches all reviews from a given pull request. */ |
| 1304 | public async fetchPullRequestReviews( |
no test coverage detected