| Conditions | 2 |
| Paths | 2 |
| Total Lines | 15 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 38 | public function generate($array, $skeleton) |
||
| 39 | { |
||
| 40 | $parts = explode('.', $this->file->getPathName()); |
||
|
|
|||
| 41 | array_pop($parts); |
||
| 42 | |||
| 43 | $file = implode('.', $parts) . '.yml'; |
||
| 44 | |||
| 45 | if (file_exists($file)) { |
||
| 46 | return; |
||
| 47 | } |
||
| 48 | |||
| 49 | $this->renderFile($skeleton, $file, array( |
||
| 50 | 'array' => $array, |
||
| 51 | )); |
||
| 52 | } |
||
| 53 | } |
||
| 54 |
Methods can only be called on objects. This check looks for methods being called on variables that have been inferred to never be objects.