Conditions | 4 |
Paths | 4 |
Total Lines | 19 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
29 | public function getDefaultThumbImage(array $options = []) |
||
30 | { |
||
31 | $thumbnailModel = $this->getThumbnailModel(); |
||
32 | |||
33 | if (null === $thumbnailModel){ |
||
34 | return null; |
||
35 | } |
||
36 | |||
37 | $url = $thumbnailModel->getThumbUrl(MFUModule::THUMB_ALIAS_DEFAULT); |
||
38 | |||
39 | if (empty($url)) { |
||
40 | return null; |
||
41 | } |
||
42 | |||
43 | if (empty($options['alt'])) { |
||
44 | $options['alt'] = $thumbnailModel->alt; |
||
45 | } |
||
46 | |||
47 | return Html::img($url, $options); |
||
48 | } |
||
67 | } |