Passed
Pull Request — master (#2)
by Andreas
11:41
created

ThreedSecureAuthenticateTransaction::canCommit()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 6

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 2
c 1
b 0
f 0
dl 0
loc 4
ccs 0
cts 3
cp 0
rs 10
cc 2
nc 2
nop 0
crap 6
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Larium\Pay\Transaction;
6
7
class ThreedSecureAuthenticateTransaction implements ThreedSecureAuthenticate
8
{
9
    use Commit;
10
11
    private $pares;
12
13
    private $transactionId;
14
15 1
    public function __construct($pares, $transactionId)
16
    {
17 1
        $this->pares = $pares;
18 1
        $this->transactionId = $transactionId;
19
    }
20
21
    public function getPares()
22
    {
23
        return $this->pares;
24
    }
25
26
    public function getTransactionId()
27
    {
28
        return $this->transactionId;
29
    }
30
31
    public function canCommit()
32
    {
33
        return $this->pares
34
            && $this->transactionId;
35
    }
36
}
37