Completed
Push — v4.0 ( 3a8f05...488a49 )
by
unknown
03:09
created

PlatesRenderTemplate   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
dl 0
loc 11
rs 10
c 0
b 0
f 0
wmc 2
lcom 0
cbo 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A renderTemplate() 0 8 2
1
<?php
2
3
namespace League\Plates\RenderTemplate;
4
5
use League\Plates;
6
7
class PlatesRenderTemplate implements Plates\RenderTemplate
8
{
9
    public function renderTemplate(Plates\Template $template) {
10
        $context = $template->getContext();
11
        if (isset($context['layout'])) {
12
            return $this->renderTemplate($context['layout']);
13
        }
14
15
        return (string) $template->getContent();
16
    }
17
}
18