GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Test Failed
Pull Request — master (#73)
by Yong
08:31 queued 12s
created

RequestTrait::roa()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 1
dl 0
loc 3
ccs 0
cts 0
cp 0
crap 2
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace AlibabaCloud\Client\Traits;
4
5
use AlibabaCloud\Client\AlibabaCloud;
6
use AlibabaCloud\Client\Exception\ClientException;
7
use AlibabaCloud\Client\Filter;
8
use AlibabaCloud\Client\Request\RoaRequest;
9
use AlibabaCloud\Client\Request\RpcRequest;
10
use AlibabaCloud\Client\Request\UserAgent;
11
12
/**
13
 * Trait RequestTrait
14
 *
15
 * @package   AlibabaCloud\Client\Traits
16
 *
17
 * @mixin     AlibabaCloud
18
 */
19
trait RequestTrait
20
{
21
    /**
22
     * @param string $name
23 4
     * @param string $value
24
     *
25 4
     * @throws ClientException
26 4
     */
27
    public static function appendUserAgent($name, $value)
28
    {
29
        Filter::name($name);
30
        Filter::value($value);
31 2
32
        UserAgent::append($name, $value);
33 2
    }
34 2
35
    /**
36
     * @param array $userAgent
37
     */
38
    public static function withUserAgent(array $userAgent)
39
    {
40
        UserAgent::with($userAgent);
41 1
    }
42
43 1
    /**
44
     * @deprecated
45
     * @codeCoverageIgnore
46
     *
47
     * @param array $options
48
     *
49
     * @return RpcRequest
50
     * @throws ClientException
51 3
     */
52
    public static function rpcRequest(array $options = [])
53 3
    {
54
        return self::rpc($options);
55
    }
56
57
    /**
58
     * @deprecated
59
     * @codeCoverageIgnore
60
     *
61
     * @param array $options
62
     *
63
     * @return RoaRequest
64
     * @throws ClientException
65
     */
66
    public static function roaRequest(array $options = [])
67
    {
68
        return self::roa($options);
69
    }
70
71
    /**
72
     * @param array $options
73
     *
74
     * @return RpcRequest
75
     * @throws ClientException
76
     */
77
    public static function rpc(array $options = [])
78
    {
79
        return new RpcRequest($options);
80
    }
81
82
    /**
83
     * @param array $options
84
     *
85
     * @return RoaRequest
86
     * @throws ClientException
87
     */
88
    public static function roa(array $options = [])
89
    {
90
        return new RoaRequest($options);
91
    }
92
}
93