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.

Code Duplication    Length = 68-70 lines in 2 locations

src/CloudFlare/User/LoadBalancers/Maps.php 1 location

@@ 18-87 (lines=70) @@
15
 *
16
 * @version 1
17
 */
18
class Maps extends Api
19
{
20
    /**
21
     * List maps
22
     * List configured maps
23
     */
24
    public function maps()
25
    {
26
        return $this->get('/user/load_balancers/maps');
27
    }
28
29
    /**
30
     * Create a map
31
     * Create a new map
32
     *
33
     * @param array       $global_pools Sorted list of pool IDs that will be utilized
34
     *                                  if a CF PoP cannot be assigned to a configured region.
35
     * @param string|null $description Object description.
36
     */
37
    public function create($global_pools, $description = null)
38
    {
39
        $data = [
40
            'global_pools' => $global_pools,
41
            'description'  => $description,
42
        ];
43
44
        return $this->post('/user/load_balancers/maps', $data);
45
    }
46
47
    /**
48
     * Map details
49
     * Fetch a single configured map
50
     *
51
     * @param string $identifier
52
     */
53
    public function details($identifier)
54
    {
55
        return $this->get('/user/load_balancers/maps/' . $identifier);
56
    }
57
58
    /**
59
     * Modify a map
60
     * Modify a configured map
61
     *
62
     * @param string      $identifier
63
     * @param array       $global_pools Sorted list of pool IDs that will be utilized
64
     *                                  if a CF PoP cannot be assigned to a configured region.
65
     * @param string|null $description  Object description.
66
     */
67
    public function update($identifier, $global_pools = null, $description = null)
68
    {
69
        $data = [
70
            'global_pools' => $global_pools,
71
            'description'  => $description,
72
        ];
73
74
        return $this->patch('/user/load_balancers/maps/' . $identifier, $data);
75
    }
76
77
    /**
78
     * Delete a map
79
     * Delete a configured map
80
     *
81
     * @param string $identifier
82
     */
83
    public function delete_map($identifier)
84
    {
85
        return $this->delete('/user/load_balancers/maps/' . $identifier);
86
    }
87
}
88

src/CloudFlare/User/LoadBalancers/Notifiers.php 1 location

@@ 18-85 (lines=68) @@
15
 *
16
 * @version 1
17
 */
18
class Notifiers extends Api
19
{
20
    /**
21
     * List notifiers
22
     * List configured notifiers for a user
23
     */
24
    public function notifiers()
25
    {
26
        return $this->get('/user/load_balancers/notifiers');
27
    }
28
29
    /**
30
     * Create a notifier
31
     * Create a configured notifier
32
     *
33
     * @param string      $address Notifier address
34
     * @param string|null $type    Notifier type
35
     */
36
    public function create($address, $type = null)
37
    {
38
        $data = [
39
            'address' => $address,
40
            'type'    => $type,
41
        ];
42
43
        return $this->post('/user/load_balancers/notifiers', $data);
44
    }
45
46
    /**
47
     * Notifier details
48
     * Fetch a single configured CTM notifier for a user
49
     *
50
     * @param string $identifier
51
     */
52
    public function details($identifier)
53
    {
54
        return $this->get('/user/load_balancers/notifiers/' . $identifier);
55
    }
56
57
    /**
58
     * Modify a notifier
59
     * Modify a configured notifier
60
     *
61
     * @param string      $identifier
62
     * @param string|null $address Notifier address
63
     * @param string|null $type    Notifier type
64
     */
65
    public function update($identifier, $address = null, $type = null)
66
    {
67
        $data = [
68
            'address' => $address,
69
            'type'    => $type,
70
        ];
71
72
        return $this->patch('/user/load_balancers/notifiers/' . $identifier, $data);
73
    }
74
75
    /**
76
     * Delete a notifier
77
     * Delete a configured notifier
78
     *
79
     * @param string $identifier
80
     */
81
    public function delete_notifier($identifier)
82
    {
83
        return $this->delete('/user/load_balancers/notifiers/' . $identifier);
84
    }
85
}
86