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.

CustomPages::details()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 2
1
<?php
2
3
namespace Cloudflare\Zone;
4
5
use Cloudflare\Api;
6
7
/**
8
 * CloudFlare API wrapper
9
 *
10
 * Custom Pages for a Zone
11
 *
12
 * @author James Bell <[email protected]>
13
 *
14
 * @version 1
15
 */
16
class CustomPages extends Api
17
{
18
    /**
19
     * Available Custom Pages (permission needed: #zone_settings:read)
20
     *
21
     * @param string $zone_identifier API item identifier tag
22
     */
23
    public function custom_pages($zone_identifier)
24
    {
25
        return $this->get('zones/'.$zone_identifier.'/custom_pages');
26
    }
27
28
    /**
29
     * Custom Page details (permission needed: #zone_settings:read)
30
     * Details about a specific Custom page details
31
     *
32
     * @param string $zone_identifier API item identifier tag
33
     * @param string $identifier
34
     */
35
    public function details($zone_identifier, $identifier)
36
    {
37
        return $this->get('zones/'.$zone_identifier.'/custom_pages/'.$identifier);
38
    }
39
40
    /**
41
     * Update Custom page URL (permission needed: #zone_settings:edit)
42
     * Update Custom page URL
43
     *
44
     * @param string $zone_identifier API item identifier tag
45
     * @param string $identifier
46
     * @param string $url             A URL that is associated with the Custom Page.
47
     * @param string $state           The Custom Page state
48
     */
49
    public function update($zone_identifier, $identifier, $url, $state)
50
    {
51
        $data = [
52
            'url'   => $url,
53
            'state' => $state,
54
        ];
55
56
        return $this->patch('zones/'.$zone_identifier.'/custom_pages/'.$identifier, $data);
57
    }
58
}
59