Code Duplication    Length = 14-14 lines in 2 locations

src/Mailgun/Model/Message/SendResponse.php 1 location

@@ 44-57 (lines=14) @@
41
     *
42
     * @return SendResponse
43
     */
44
    public static function create(array $data)
45
    {
46
        $id = '';
47
        $message = '';
48
49
        if (isset($data['id'])) {
50
            $id = $data['id'];
51
        }
52
        if (isset($data['message'])) {
53
            $message = $data['message'];
54
        }
55
56
        return new self($id, $message);
57
    }
58
59
    /**
60
     * @return string

src/Mailgun/Model/Webhook/BaseResponse.php 1 location

@@ 46-59 (lines=14) @@
43
     *
44
     * @return static
45
     */
46
    public static function create(array $data)
47
    {
48
        $webhook = [];
49
        $message = '';
50
        if (isset($data['webhook'])) {
51
            $webhook = $data['webhook'];
52
        }
53
54
        if (isset($data['message'])) {
55
            $message = $data['message'];
56
        }
57
58
        return new static($webhook, $message);
59
    }
60
61
    /**
62
     * @return string|null