Skip to content

Commit

Permalink
Close #30 Merge branch 'fix/doc-block'
Browse files Browse the repository at this point in the history
  • Loading branch information
Gianluca Arbezzano committed Feb 26, 2015
2 parents dc7dc2f + c8c48c5 commit 80d52fb
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
9 changes: 6 additions & 3 deletions src/EdpGithub/Api/CurrentUser.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,17 @@ public function show()
*
* @link http://developer.github.com/v3/repos/
* @param array $params
* @return array
* @return RepositoryCollection
*/
public function repos(array $params = array())
{
$httpClient =$this->getClient()->getHttpClient();
$collection = new RepositoryCollection($httpClient, 'user/repos', $params);

return $collection;
return new RepositoryCollection(
$httpClient,
'user/repos',
$params
);
}

/**
Expand Down
7 changes: 5 additions & 2 deletions src/EdpGithub/Api/User.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,12 @@ public function show($username)
public function repos($username, array $params = array())
{
$httpClient =$this->getClient()->getHttpClient();
$collection = new RepositoryCollection($httpClient, 'users/'.urlencode($username).'/repos', $params);

return $collection;
return new RepositoryCollection(
$httpClient,
'users/' . urlencode($username) . '/repos',
$params
);
}

/**
Expand Down

0 comments on commit 80d52fb

Please sign in to comment.