Code Duplication    Length = 11-13 lines in 2 locations

src/Laposta.php 2 locations

@@ 69-81 (lines=13) @@
66
        return $list;
67
    }
68
69
    public function createList(List_ $list)
70
    {
71
        $data = $this->post('list', [
72
            'form_params' => [
73
                'name' => $list->getName(),
74
                'remarks' => $list->getRemarks(),
75
                'subscribe_notification_email' => $list->getSubscribeNotificationEmail(),
76
                'unsubscribe_notification_email' => $list->getUnsubsribeNotificationEmail(),
77
            ],
78
        ]);
79
80
        $list->updateFromResponse($data['list']);
81
    }
82
83
    public function updateList(List_ $list)
84
    {
@@ 83-93 (lines=11) @@
80
        $list->updateFromResponse($data['list']);
81
    }
82
83
    public function updateList(List_ $list)
84
    {
85
        $this->client->post('list/'.$list->getListId(), [
86
            'form_params' => [
87
                'name' => $list->getName(),
88
                'remarks' => $list->getRemarks(),
89
                'subscribe_notification_email' => $list->getSubscribeNotificationEmail(),
90
                'unsubscribe_notification_email' => $list->getUnsubsribeNotificationEmail(),
91
            ],
92
        ]);
93
    }
94
95
    private function get($uri, $options = [])
96
    {