Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/github_helper.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Molakvoæ <skjnldsv@protonmail.com>2022-08-18 11:17:24 +0300
committerJohn Molakvoæ <skjnldsv@protonmail.com>2022-08-18 11:17:24 +0300
commit9688ff7a092b06549914e12767d23c0d4f128c85 (patch)
tree739f59276f33b87ded26eae367bd42d8fa9aef16
parentb3b77807ca6eb528ba506acb03e31d143210797b (diff)
Fix graphql error if no PR to check
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
-rw-r--r--changelog/index.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/changelog/index.php b/changelog/index.php
index eb664ca..1e4db32 100644
--- a/changelog/index.php
+++ b/changelog/index.php
@@ -333,12 +333,18 @@ QUERY;
QUERY;
$progressBar->setMessage("Fetching PR titles for $repoName ...");
- $response = $client->api('graphql')->execute($query);
+ if (count($pullRequests) === 0) {
+ $progressBar->advance();
+ continue;
+ }
+
+ $response = $client->api('graphql')->execute($query);
if (!isset($response['data']['repository'])) {
$progressBar->advance();
continue;
}
+
foreach ($response['data']['repository'] as $pr) {
if ($this->shouldPRBeSkipped($pr['title'])) {
continue;