Conditions | 1 |
Paths | 1 |
Total Lines | 17 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
37 | public function jsonSerialize(): array |
||
38 | { |
||
39 | $payload = [ |
||
40 | 'template_type' => Template::TYPE_AIRLINE_BOARDINGPASS, |
||
41 | 'intro_message' => $this->introMessage, |
||
42 | 'locale' => $this->locale, |
||
43 | 'theme_color' => $this->themeColor, |
||
44 | 'boarding_pass' => $this->boardingPass, |
||
45 | ]; |
||
46 | |||
47 | $json = parent::jsonSerialize(); |
||
48 | $json += [ |
||
49 | 'payload' => array_filter($payload) |
||
50 | ]; |
||
51 | |||
52 | return $json; |
||
53 | } |
||
54 | } |
||
55 |