Completed
Push — master ( 1842cb...2414f9 )
by ARCANEDEV
03:37
created

InvalidTrendUnitException::make()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
c 0
b 0
f 0
ccs 2
cts 2
cp 1
rs 10
cc 1
nc 1
nop 1
crap 1
1
<?php namespace Arcanedev\LaravelMetrics\Exceptions;
2
3
use InvalidArgumentException;
4
5
/**
6
 * Class     InvalidTrendUnitException
7
 *
8
 * @package  Arcanedev\LaravelMetrics\Exceptions
9
 * @author   ARCANEDEV <[email protected]>
10
 */
11
class InvalidTrendUnitException extends InvalidArgumentException
12
{
13
    /**
14
     * Make a new exception.
15
     *
16
     * @param  string  $unit
17
     *
18
     * @return \Arcanedev\LaravelMetrics\Exceptions\InvalidTrendUnitException
19
     */
20 24
    public static function make(string $unit)
21
    {
22 24
        return new static("Invalid trend unit provided [{$unit}]");
23
    }
24
}
25