Directory::createIfNotExists()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 7
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 7
rs 9.4285
c 0
b 0
f 0
cc 2
eloc 3
nc 2
nop 4
1
<?php
2
3
namespace Scaffolder\Support;
4
5
use Illuminate\Support\Facades\File;
6
7
class Directory
8
{
9
	public static function createIfNotExists($path, $mode = 0755, $recursive = false, $force = false)
10
	{
11
		if (!File::isDirectory($path))
12
		{
13
			File::makeDirectory($path, $mode, $recursive , $force );
14
		}
15
	}
16
17
18
}
19
20