(head: string, base: string)
| 109 | * Find an open PR from a specific branch to a base branch |
| 110 | */ |
| 111 | export async function findOpenPr(head: string, base: string) { |
| 112 | let response = await request("GET /repos/{owner}/{repo}/pulls", { |
| 113 | ...requestOptions(), |
| 114 | state: "open", |
| 115 | head: `${OWNER}:${head}`, |
| 116 | base, |
| 117 | }); |
| 118 | |
| 119 | return response.data.length > 0 ? response.data[0] : null; |
| 120 | } |
| 121 | |
| 122 | /** |
| 123 | * Create a new PR |
no test coverage detected