| Conditions | 2 |
| Paths | 2 |
| Total Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 6 |
| Changes | 0 | ||
| 1 | <?php namespace Arcanedev\Assets\Pipes\Init; |
||
| 28 | public function handle(array $passable, Closure $next) |
||
| 29 | { |
||
| 30 | $path = $passable['root-directory'].'/'.$passable['name']; |
||
| 31 | |||
| 32 | if (File::isDirectory($path)) |
||
| 33 | DirectoryExistsException::throw($path); |
||
| 34 | |||
| 35 | File::makeDirectory($path, 0755, true); |
||
| 36 | |||
| 37 | return $next($passable + compact('path')); |
||
| 38 | } |
||
| 39 | } |
||
| 40 |