Skip to content

Commit bf83136

Browse files
committed
add award_emoji API's
1 parent 00dbf59 commit bf83136

File tree

3 files changed

+33
-0
lines changed

3 files changed

+33
-0
lines changed

lib/Gitlab/Api/Issues.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,4 +198,15 @@ public function getTimeStats($project_id, $issue_iid)
198198
{
199199
return $this->get($this->getProjectPath($project_id, 'issues/'.$this->encodePath($issue_iid) .'/time_stats'));
200200
}
201+
202+
/**
203+
* @param int $project_id
204+
* @param int $issue_iid
205+
*
206+
* @return mixed
207+
*/
208+
public function awardEmoji($project_id, $issue_iid)
209+
{
210+
return $this->get($this->getProjectPath($project_id, 'issues/'.$this->encodePath($issue_iid).'/award_emoji'));
211+
}
201212
}

lib/Gitlab/Api/MergeRequests.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -242,4 +242,15 @@ public function unapprove($project_id, $merge_request_iid)
242242
{
243243
return $this->post($this->getProjectPath($project_id, 'merge_requests/'.$this->encodePath($merge_request_iid).'/unapprove'));
244244
}
245+
246+
/**
247+
* @param int $project_id
248+
* @param int $merge_request_iid
249+
*
250+
* @return mixed
251+
*/
252+
public function awardEmoji($project_id, $merge_request_iid)
253+
{
254+
return $this->get($this->getProjectPath($project_id, 'merge_requests/'.$this->encodePath($merge_request_iid).'/award_emoji'));
255+
}
245256
}

lib/Gitlab/Api/Snippets.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,4 +67,15 @@ public function remove($project_id, $snippet_id)
6767
{
6868
return $this->delete($this->getProjectPath($project_id, 'snippets/'.$this->encodePath($snippet_id)));
6969
}
70+
71+
/**
72+
* @param int $project_id
73+
* @param int $snippet_id
74+
*
75+
* @return mixed
76+
*/
77+
public function awardEmoji($project_id, $snippet_id)
78+
{
79+
return $this->get($this->getProjectPath($project_id, 'snippets/'.$this->encodePath($snippet_id).'/award_emoji'));
80+
}
7081
}

0 commit comments

Comments
 (0)