From a9c586891006814b58dbdb2cb5c9bae38244bc8a Mon Sep 17 00:00:00 2001 From: Yahnis Elsts Date: Thu, 24 Sep 2015 14:59:32 +0300 Subject: [PATCH] Fix a bug in GitHub support where update installation sometimes didn't work when using a private repository. --- github-checker.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/github-checker.php b/github-checker.php index 91b12e3..6441176 100644 --- a/github-checker.php +++ b/github-checker.php @@ -94,6 +94,8 @@ class PucGitHubChecker_2_2 extends PluginUpdateChecker_2_2 { if ( empty($info->download_url) ) { $info->download_url = $this->buildArchiveDownloadUrl($ref); + } else if ( !empty($this->accessToken) ) { + $info->download_url = add_query_arg('access_token', $this->accessToken, $info->download_url); } //Get headers from the main plugin file in this branch/tag. Its "Version" header and other metadata