Conditions | 1 |
Paths | 1 |
Total Lines | 10 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 2 |
Changes | 0 |
1 | <?php |
||
12 | public function handle(Jigsaw $jigsaw): void |
||
13 | { |
||
14 | $robots = $jigsaw->app->make(JigsawRobotsTxtFactory::class); |
||
15 | $fileGenerator = $jigsaw->app->make(GenerateRobotsTxtFile::class); |
||
16 | $outputFile = $fileGenerator->execute( |
||
17 | $robots->newRobotsTxtFromConfiguration($jigsaw->getConfig('robots.RobotsTxt')), |
||
18 | $jigsaw->getDestinationPath() . '/robots.txt' |
||
19 | ); |
||
20 | |||
21 | file_put_contents($outputFile->path(), $outputFile->content()); |
||
22 | } |
||
24 |