RefundResponse::isSuccessful()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 2
nc 2
nop 0
crap 2
1
<?php
2
3
namespace Omnipay\AllPay\Message;
4
5
use Omnipay\Common\Message\RequestInterface;
6
7
class RefundResponse extends Response
8
{
9 6
    public function getTransactionReference()
10
    {
11 6
        if (isset($this->data['transID'])) {
12 3
            return $this->data['transID'];
13
        }
14 3
    }
15
16 6
    public function isSuccessful()
17
    {
18 6
        return isset($this->data['RespCode']) && $this->data['RespCode'] == '00';
19
    }
20
21 3
    public function getMessage()
22
    {
23 3
        return $this->data['RespMsg'];
24
    }
25
}
26