| Conditions | 2 |
| Paths | 2 |
| Total Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 25 | protected function getPath($name): string |
||
| 26 | { |
||
| 27 | $name = str_replace_first($this->rootNamespace(), $this->moduleName().DIRECTORY_SEPARATOR.'database'.DIRECTORY_SEPARATOR.'factories', $name); |
||
|
|
|||
| 28 | |||
| 29 | if (! $this->files->exists($path = $this->laravel['path'].DIRECTORY_SEPARATOR.$this->moduleName().DIRECTORY_SEPARATOR)) { |
||
| 30 | throw new \Exception("Invalid path: {$path}"); |
||
| 31 | } |
||
| 32 | |||
| 33 | return $this->laravel['path'].DIRECTORY_SEPARATOR.str_replace('\\', DIRECTORY_SEPARATOR, $name).'.php'; |
||
| 34 | } |
||
| 35 | } |
||
| 36 |
Overly long lines are hard to read on any screen. Most code styles therefor impose a maximum limit on the number of characters in a line.