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.
Completed
Pull Request — master (#39)
by Rubens
01:53
created

Charge::fraud_review()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 1
crap 1
1
<?php
2
3
namespace Vindi;
4
5
class Charge extends Resource
6
{
7
    /**
8
     * The endpoint that will hit the API.
9
     *
10
     * @return string
11
     */
12 24
    public function endpoint()
13
    {
14 24
        return 'charges';
15
    }
16
17
    /**
18
     * Make a POST request to charges/{id}/reissue.
19
     *
20
     * @param int $id The resource's id.
21
     * @param array $form_params
22
     *
23
     * @return mixed
24
     * @throws Exceptions\RateLimitException
25
     * @throws Exceptions\RequestException
26
     * @throws \GuzzleHttp\Exception\GuzzleException
27
     */
28 2
    public function reissue($id, array $form_params = [])
29
    {
30 2
        return $this->post($id, 'reissue', $form_params);
31
    }
32
33
    /**
34
     * Make a POST request to charges/{id}/charge.
35
     *
36
     * @param int $id The resource's id.
37
     * @param array $form_params
38
     *
39
     * @return mixed
40
     * @throws Exceptions\RateLimitException
41
     * @throws Exceptions\RequestException
42
     * @throws \GuzzleHttp\Exception\GuzzleException
43
     */
44 2
    public function charge($id, array $form_params = [])
0 ignored issues
show
Coding Style Best Practice introduced by
Please use __construct() instead of a PHP4-style constructor that is named after the class.
Loading history...
45
    {
46 2
        return $this->post($id, 'charge', $form_params);
47
    }
48
49
    /**
50
     * Make a POST request to charges/{id}/refund.
51
     *
52
     * @param int $id The resource's id.
53
     *
54
     * @return mixed
55
     * @throws Exceptions\RateLimitException
56
     * @throws Exceptions\RequestException
57
     * @throws \GuzzleHttp\Exception\GuzzleException
58
     */
59 2
    public function refund($id)
60
    {
61 2
        return $this->post($id, 'refund');
62
    }
63
64
    /**
65
     * Make a POST request to charges/{id}/fraud_review.
66
     *
67
     * @param int $id The resource's id.
68
     *
69
     * @return mixed
70
     * @throws Exceptions\RateLimitException
71
     * @throws Exceptions\RequestException
72
     * @throws \GuzzleHttp\Exception\GuzzleException
73
     */
74 2
    public function fraud_review($id)
75
    {
76 2
        return $this->post($id, 'fraud_review');
77
    }
78
}
79