Completed
Push — master ( 64f309...275242 )
by Andrii
07:38
created

ErrorMultiCurrencyException::__construct()   A

Complexity

Conditions 2
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 6

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 0
cts 0
cp 0
rs 10
c 0
b 0
f 0
cc 2
nc 1
nop 3
crap 6
1
<?php
2
3
namespace hipanel\modules\finance\cart;
4
5
use yii\base\Exception;
6
7
class ErrorMultiCurrencyException extends ErrorPurchaseException
8
{
9
    /**
10
     * {@inheritDoc}
11
     */
12
    public function __construct($message, $purchase, Exception $previous = null)
13
    {
14
        parent::__construct(!empty($message) ? $message : 'Can not add this item to cart because of different currency', $purchase, $previous);
15
    }
16
}
17