At the time we have a reference to `baseRepo`, we might still not have contacted the API nor obtained any information about the default branch for the repository. This expands the `PullRequests()` query to always report the default branch so we may choose how to render entries that belong on the current branch.
47 lines
1.1 KiB
JSON
47 lines
1.1 KiB
JSON
{
|
|
"data": {
|
|
"repository": {
|
|
"defaultBranchRef": { "name": "master" },
|
|
"pullRequests": {
|
|
"totalCount": 1,
|
|
"edges": [
|
|
{
|
|
"node": {
|
|
"number": 8,
|
|
"title": "Blueberries are a good fruit",
|
|
"state": "MERGED",
|
|
"url": "https://github.com/cli/cli/pull/8",
|
|
"headRefName": "blueberries",
|
|
"reviewDecision": "CHANGES_REQUESTED",
|
|
"commits": {
|
|
"nodes": [
|
|
{
|
|
"commit": {
|
|
"statusCheckRollup": {
|
|
"contexts": {
|
|
"nodes": [
|
|
{
|
|
"state": "SUCCESS"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"viewerCreated": {
|
|
"totalCount": 0,
|
|
"edges": []
|
|
},
|
|
"reviewRequested": {
|
|
"totalCount": 0,
|
|
"edges": []
|
|
}
|
|
}
|
|
}
|