Completed
Push — master ( 759a1b...0704c6 )
by Mark
01:43
created

ListTransformer::toFormParams()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 9
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
c 0
b 0
f 0
dl 0
loc 9
rs 9.6666
cc 1
eloc 6
nc 1
nop 1
1
<?php
2
3
namespace Mrkj\Laposta\Transformers;
4
5
use Mrkj\Laposta\Models\List_;
6
7
class ListTransformer
8
{
9
    /**
10
     * @param List_ $list
11
     * @return array
12
     */
13
    public static function toFormParams(List_ $list)
14
    {
15
        return [
16
            'name' => $list->getName(),
17
            'remarks' => $list->getRemarks(),
18
            'subscribe_notification_email' => $list->getSubscribeNotificationEmail(),
19
            'unsubscribe_notification_email' => $list->getUnsubsribeNotificationEmail(),
20
        ];
21
    }
22
}
23