| Conditions | 4 |
| Paths | 3 |
| Total Lines | 9 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 15 | public function renderTemplate(Plates\Template $template, Plates\RenderTemplate $rt = null) { |
||
| 16 | foreach ($this->render_sets as list($match, $render)) { |
||
| 17 | if ($match($template)) { |
||
| 18 | return $render->renderTemplate($template, $rt ?: $this); |
||
| 19 | } |
||
| 20 | } |
||
| 21 | |||
| 22 | throw new Plates\Exception\RenderTemplateException('No renderer was available for the template: ' . $template->name); |
||
| 23 | } |
||
| 24 | } |
||
| 25 |