projects
/
pharext
/
pharext.org
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
|
github
raw
|
inline
| side by side
many small updates
[pharext/pharext.org]
/
app
/
Github
/
API.php
diff --git
a/app/Github/API.php
b/app/Github/API.php
index 381533d298e8d6d2f2efe54a48a88488505913c6..10cf2c0c33640f90f9dfbbc360b69366f4d0c000 100644
(file)
--- a/
app/Github/API.php
+++ b/
app/Github/API.php
@@
-111,6
+111,11
@@
class API
$fetch = new Fetch\Token($this, compact("code") + $this->config->client->toArray());
return $fetch($callback);
}
$fetch = new Fetch\Token($this, compact("code") + $this->config->client->toArray());
return $fetch($callback);
}
+
+ function fetchUser(callable $callback) {
+ $fetch = new Fetch\User($this);
+ return $fetch($callback);
+ }
function fetchRepos($page, callable $callback) {
$fetch = new Fetch\Repos($this);
function fetchRepos($page, callable $callback) {
$fetch = new Fetch\Repos($this);
@@
-139,4
+144,9
@@
class API
$fetch->setPage($page);
return $fetch($callback);
}
$fetch->setPage($page);
return $fetch($callback);
}
+
+ function fetchContents($repo, $path, callable $callback) {
+ $fetch = new Fetch\Contents($this, compact("repo", "path"));
+ return $fetch($callback);
+ }
}
}