Test Failed
Push — master ( a6006f...8cc230 )
by Robin
12:30
created

SmsClient::getPageCode()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 0
cts 2
cp 0
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 1
crap 2
1
<?php
2
3
namespace Klever\JustGivingApiSdk\ResourceClients;
4
5
class SmsClient extends BaseClient
6
{
7
    protected $aliases = [
8
        'getPageCode'           => 'RetrievePageSmsCode',
9
        'updatePageCode'        => 'UpdatePageSmsCode',
10
        'checkCodeAvailability' => 'CheckSmsCodeAvailability',
11
    ];
12
13
    public function getPageCode($pageShortName)
14
    {
15
        return $this->get("fundraising/pages/" . $pageShortName . "/sms");
16
    }
17
18 1
    public function updatePageCode($pageShortName, $updatePageSmsCodeRequest)
19
    {
20 1
        return $this->put("fundraising/pages/" . $pageShortName . "/sms", $updatePageSmsCodeRequest);
21
    }
22
23
    public function checkCodeAvailability($urn)
24
    {
25
        return $this->post("sms/urn/" . $urn . "/check");
26
    }
27
}
28