| @@ -1,21 +1,19 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | 3 | |
| 4 | 4 | |
| 5 | -// 0 - none. | |
| 5 | +// 0 - none | |
| 6 | 6 | define( 'GEDEBUG_NONE', 0 ); |
| 7 | 7 | |
| 8 | -// 1 - call logging only. | |
| 8 | +// 1 - call logging only | |
| 9 | 9 | define( 'GEDEBUG_CALL', 1 ); |
| 10 | 10 | |
| 11 | -// 2 - calls, and responses. | |
| 11 | +// 2 - calls, and responses | |
| 12 | 12 | define( 'GEDEBUG_RESP', 2 ); |
| 13 | 13 | |
| 14 | -// Selected debug level. | |
| 15 | -if ( ! defined( 'GITHUB_API_LEVEL' ) ) { | |
| 16 | - define( 'GITHUB_API_LEVEL', GEDEBUG_NONE ); | |
| 17 | -} | |
| 14 | +// Selected debug level | |
| 15 | +define( 'GITHUB_API_LEVEL', GEDEBUG_NONE ); | |
| 18 | 16 | |
| 19 | 17 | |
| 20 | 18 | /** |
| 21 | 19 | * This class contains all the functions that actually retrieve information from the GitHub API |
| @@ -151,9 +149,9 @@ | ||
| 151 | 149 | |
| 152 | 150 | $this->log( "get_repo_milestone_summary( $owner, $repository, $milestone )", GEDEBUG_CALL ); |
| 153 | 151 | |
| 154 | 152 | $owner = trim( $owner, '/' ); |
| 155 | - $repo = trim( $repository, '/' ); | |
| 153 | + $repo = trim( $repo, '/' ); | |
| 156 | 154 | |
| 157 | 155 | $results = $this->call_api( "https://api.github.com/repos/$owner/$repository/milestones/$milestone" ); |
| 158 | 156 | |
| 159 | 157 | return json_decode( $results['body'] ); |