Completed
Push — master ( 48e5b8...eb0757 )
by Tobias
20:40
created

LimitExceeded::create()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 2
1
<?php
2
3
/*
4
 * Copyright (C) 2013 Mailgun
5
 *
6
 * This software may be modified and distributed under the terms
7
 * of the MIT license. See the LICENSE file for details.
8
 */
9
10
namespace Mailgun\Message\Exceptions;
11
12
use Mailgun\Exception;
13
14
class LimitExceeded extends \Exception implements Exception
15
{
16
    public static function create($field, $limit)
17
    {
18
        return new self(sprintf('You\'ve exceeded the maximum (%d) %s for a single message.', $limit, $field));
19
    }
20
}
21