| Conditions | 3 | 
| Paths | 4 | 
| Total Lines | 17 | 
| Code Lines | 11 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Tests | 9 | 
| CRAP Score | 3.054 | 
| Changes | 1 | ||
| Bugs | 0 | Features | 0 | 
| 1 | <?php  | 
            ||
| 37 | 4 | public function bake($action, $content = '')  | 
            |
| 38 |     { | 
            ||
| 39 | 4 |         if ($content === true) { | 
            |
| 40 | 4 | $content = $this->getContent($action);  | 
            |
| 41 | }  | 
            ||
| 42 | 4 |         if (empty($content)) { | 
            |
| 43 |             $this->err("<warning>No generated content for '{$action}.ctp', not generating template.</warning>"); | 
            ||
| 44 | |||
| 45 | return false;  | 
            ||
| 46 | }  | 
            ||
| 47 | 4 |         $this->out("\n" . sprintf('Baking `%s` view twig template file...', $action), 1, Shell::QUIET); | 
            |
| 48 | 4 | $path = $this->getPath();  | 
            |
| 49 | 4 | $filename = $path . Inflector::underscore($action) . '.twig';  | 
            |
| 50 | 4 | $this->createFile($filename, $content);  | 
            |
| 51 | |||
| 52 | 4 | return $content;  | 
            |
| 53 | }  | 
            ||
| 54 | }  | 
            ||
| 55 |