Conditions | 3 |
Paths | 3 |
Total Lines | 11 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
27 | public function handle(string $targetFile, string $newContent, array $parameters = null): bool |
||
28 | { |
||
29 | switch ($this->pathUtil->getExtension($targetFile)) { |
||
30 | case 'json': |
||
31 | return $this->mergeJson($targetFile, $newContent); |
||
32 | |||
33 | case 'md': |
||
34 | return $this->appendFile($targetFile, "\n---\n" . $newContent); |
||
35 | } |
||
36 | |||
37 | return false; |
||
38 | } |
||
54 |