Conditions | 4 |
Paths | 4 |
Total Lines | 15 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 10 |
CRAP Score | 4 |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
23 | 2 | protected function getContent(View $view, $format) |
|
24 | { |
||
25 | 2 | $template = $view->getTemplate(); |
|
26 | |||
27 | 2 | if (is_array($template)) { |
|
28 | 1 | foreach ($template as $t) { |
|
29 | 1 | if ($this->templating->exists($t)) { |
|
30 | 1 | $template = $t; |
|
31 | 1 | break; |
|
32 | } |
||
33 | 1 | } |
|
34 | 1 | } |
|
35 | |||
36 | 2 | return $this->templating->render($template, $view->getDataAsArray()); |
|
37 | } |
||
38 | |||
47 |