| Conditions | 2 |
| Paths | 2 |
| Total Lines | 17 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 47 | public function render($value, $object, $primary, \Twig_Environment $twig) |
||
| 48 | { |
||
| 49 | /** dont use twig if no template is provided */ |
||
| 50 | if (null === $this->getOption('template')) { |
||
| 51 | return $this->getOption('prefix').$value; |
||
| 52 | } |
||
| 53 | |||
| 54 | return $this->renderTemplate( |
||
| 55 | $twig, |
||
| 56 | $this->getOption('template'), |
||
| 57 | [ |
||
| 58 | 'value' => $this->getOption('prefux').$value, |
||
| 59 | 'object' => $object, |
||
| 60 | 'primary' => $primary, |
||
| 61 | ] |
||
| 62 | ); |
||
| 63 | } |
||
| 64 | } |
||
| 65 |