Conditions | 3 |
Paths | 3 |
Total Lines | 15 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
20 | public function run(): string |
||
21 | { |
||
22 | $flashes = $this->flash->getAll(); |
||
23 | |||
24 | $html = []; |
||
25 | foreach ($flashes as $type => $data) { |
||
26 | foreach ($data as $message) { |
||
27 | $html[] = Alert::widget() |
||
28 | ->options(['class' => "alert-{$type} shadow"]) |
||
|
|||
29 | ->body($message['body']) |
||
30 | ; |
||
31 | } |
||
32 | } |
||
33 | |||
34 | return implode($html); |
||
35 | } |
||
37 |