| Conditions | 3 |
| Paths | 3 |
| Total Lines | 13 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 3.1406 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 43 | 28 | public static function getTempBaseDir() |
|
| 44 | { |
||
| 45 | 28 | foreach (self::$tempDirs as $directory) { |
|
| 46 | 28 | if (file_exists($directory)) { |
|
| 47 | 28 | $baseDir = $directory . DIRECTORY_SEPARATOR . 'paraunit'; |
|
| 48 | 28 | self::mkdirIfNotExists($baseDir); |
|
| 49 | |||
| 50 | 28 | return $baseDir; |
|
| 51 | } |
||
| 52 | } |
||
| 53 | |||
| 54 | throw new \RuntimeException('Unable to create a temporary directory'); |
||
| 55 | } |
||
| 56 | |||
| 67 |