Notification Setup Error

We have detected an error in your notification set-up (Event-ID dab39dc24f564ec7bd4628d1305fd03c). Currently, we cannot inform you about inspection progress. Please check that the user 557058:bca11929-8c2d-43f2-8a82-c5416880d395 still has access to your repository or update the API account.

Completed
Push — develop ( 577635...cd8e32 )
by
unknown
269:51 queued 254:48
created

Milestones::get()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 6
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 3
1
<?php
2
3
/**
4
 * This file is part of the bitbucket-api package.
5
 *
6
 * (c) Alexandru G. <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Bitbucket\API\Repositories;
13
14
use Bitbucket\API;
15
use Buzz\Message\MessageInterface;
16
17
/**
18
 * @author  Alexandru G.    <[email protected]>
19
 */
20
class Milestones extends API\Api
21
{
22
    /**
23
     * Get a list of milestones
24
     *
25
     * @access public
26
     * @param  string           $account The team or individual account owning the repository.
27
     * @param  string           $repo    The repository identifier.
28
     * @return MessageInterface
29
     */
30
    public function all($account, $repo)
31
    {
32
        return $this->getClient()->setApiVersion('2.0')->get(
33
            sprintf('repositories/%s/%s/milestones', $account, $repo)
34
        );
35
    }
36
37
    /**
38
     * Get an individual milestone
39
     *
40
     * @access public
41
     * @param  string           $account     The team or individual account owning the repository.
42
     * @param  string           $repo        The repository identifier.
43
     * @param  int              $milestoneID The milestone identifier.
44
     * @return MessageInterface
45
     */
46
    public function get($account, $repo, $milestoneID)
47
    {
48
        return $this->getClient()->setApiVersion('2.0')->get(
49
            sprintf('repositories/%s/%s/milestones/%d', $account, $repo, $milestoneID)
50
        );
51
    }
52
}
53