Commit: 2f0f19f2fb9fc04c8e3d1561fb84e3738420ccae Author: Johannes Schlüter <johan...@schlueters.de> Wed, 8 May 2013 12:08:52 +0200 Parents: bfc6f84bc6efbf1e44f47879bffe6f19472ddb87 Branches: master
Link: http://git.php.net/?p=web/qa.git;a=commitdiff;h=2f0f19f2fb9fc04c8e3d1561fb84e3738420ccae Log: GitHub requires a user agent nowadays Changed paths: M pulls/api.php Diff: diff --git a/pulls/api.php b/pulls/api.php index c7e0a67..148a6df 100644 --- a/pulls/api.php +++ b/pulls/api.php @@ -1,6 +1,7 @@ <?php $errors = array(); require('./config.php'); +define('USER_AGENT', 'PHP Pull Request Admin (http://qa.php.net/pulls php-qa@lists.php.net)'); if ($_SERVER['SERVER_NAME'] === 'schlueters.de') { define('DEV', true); @@ -178,7 +179,8 @@ function ghupdate() $url = GITHUB_BASEURL.'repos/'.GITHUB_ORG.'/'.urlencode($_POST['repo']).'/pulls/'.$_POST['id']; $ctxt = stream_context_create(array( 'http' => array( - 'ignore_errors' => '1' + 'ignore_errors' => '1', + 'user_agent' => USER_AGENT, ) )); $pull_raw = @file_get_contents($url, false, $ctxt); -- PHP Quality Assurance Mailing List <http://www.php.net/> To unsubscribe, visit: http://www.php.net/unsub.php