From facf063444bef0bae216a592b8dd069edc988b02 Mon Sep 17 00:00:00 2001 From: "Georges.L" Date: Mon, 1 Aug 2016 03:11:01 +0200 Subject: [PATCH 1/2] Added missing parameters to repo/tags API --- lib/Github/Api/GitData/Tags.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/Github/Api/GitData/Tags.php b/lib/Github/Api/GitData/Tags.php index 4b2d0341ef3..07fdf6d15f6 100644 --- a/lib/Github/Api/GitData/Tags.php +++ b/lib/Github/Api/GitData/Tags.php @@ -16,12 +16,13 @@ class Tags extends AbstractApi * * @param string $username * @param string $repository + * @param array $params the additional parameters like milestone, assignees, labels, sort, direction * * @return array */ - public function all($username, $repository) + public function all($username, $repository, array $params = []) { - return $this->get('repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/git/refs/tags'); + return $this->get('repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/git/refs/tags', $params); } /** From 704f8fbd9d7efa87fbf830cac4d4efe46369880c Mon Sep 17 00:00:00 2001 From: "Georges.L" Date: Mon, 1 Aug 2016 03:46:32 +0200 Subject: [PATCH 2/2] Added missing parameters to repo/tags API, again --- lib/Github/Api/GitData/Tags.php | 5 ++--- lib/Github/Api/Repo.php | 5 +++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/Github/Api/GitData/Tags.php b/lib/Github/Api/GitData/Tags.php index 07fdf6d15f6..4b2d0341ef3 100644 --- a/lib/Github/Api/GitData/Tags.php +++ b/lib/Github/Api/GitData/Tags.php @@ -16,13 +16,12 @@ class Tags extends AbstractApi * * @param string $username * @param string $repository - * @param array $params the additional parameters like milestone, assignees, labels, sort, direction * * @return array */ - public function all($username, $repository, array $params = []) + public function all($username, $repository) { - return $this->get('repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/git/refs/tags', $params); + return $this->get('repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/git/refs/tags'); } /** diff --git a/lib/Github/Api/Repo.php b/lib/Github/Api/Repo.php index 9d98c3f1fe5..755c23bb91c 100644 --- a/lib/Github/Api/Repo.php +++ b/lib/Github/Api/Repo.php @@ -420,12 +420,13 @@ public function languages($username, $repository) * * @param string $username the user who owns the repository * @param string $repository the name of the repository + * @param array $params the additional parameters like milestone, assignees, labels, sort, direction * * @return array list of the repository tags */ - public function tags($username, $repository) + public function tags($username, $repository, array $params = []) { - return $this->get('repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/tags'); + return $this->get('repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/tags', $params); } /**