RefundResponse   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 5
c 1
b 0
f 0
dl 0
loc 12
ccs 5
cts 5
cp 1
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A isSuccessful() 0 7 1
1
<?php
2
3
namespace Omnipay\IcepayPayments\Message;
4
5
/**
6
 * The response after telling Icepay to refund a transaction or order.
7
 */
8
class RefundResponse extends AbstractResponse
9
{
10
    /**
11
     * {@inheritdoc}
12
     */
13 2
    public function isSuccessful(): bool
14
    {
15 2
        return in_array(
16 2
            $this->data['RefundStatusCode'],
17
            [
18 2
                self::RESPONSE_STATUS_COMPLETED,
19 2
                self::RESPONSE_STATUS_REFUND,
20
            ]
21
        );
22
    }
23
}
24