yet another github api refactoring
[pharext/pharext.org] / app / Github / API / Repos / RepoCallback.php
1 <?php
2
3 namespace app\Github\API\Repos;
4
5 use app\Github\API\Callback;
6 use app\Github\API\Hooks\HooksCallback;
7 use app\Github\API\Tags\TagsCallback;
8
9 class RepoCallback extends Callback
10 {
11 function __invoke($repo, $links = null) {
12 $this->api->listHooks($repo->full_name, new HooksCallback($this->api, $repo));
13 $this->api->listTags($repo->full_name, 1, new TagsCallback($this->api, $repo));
14 $this->api->listReleases($repo->full_name, 1, new ReleasesCallback($this->api, $repo));
15 $this->api->readContents($repo->full_name, null, new ContentsCallback($this->api, $repo));;
16 }
17 }