CouldNotCreateMessage::invalidIndent()   A
last analyzed

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
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
crap 1
1
<?php
2
3
namespace NotificationChannels\Todoist\Exceptions;
4
5
class CouldNotCreateMessage extends \Exception
6
{
7 1
    public static function invalidPriority($priority)
8
    {
9 1
        return new static("Priority `{$priority}` is invalid. It should be a number between 1 and 4, 4 for very urgent and 1 for natural.");
10
    }
11
12 1
    public static function invalidIndent($indent)
13
    {
14 1
        return new static("Indent `{$indent}` is invalid. It should be a a number between 1 and 4, where 1 is top-level.");
15
    }
16
}
17