| @@ 95-97 (lines=3) @@ | ||
| 92 | public static function recurseCopy($src, $dst) | |
| 93 |     { | |
| 94 | $dir = opendir($src); | |
| 95 |         if (!@mkdir($dst, 0777) && !is_dir($dst)) { | |
| 96 |             throw new Exception('Copy dir error, access denied for path: '.$dst); | |
| 97 | } | |
| 98 | ||
| 99 |         while (false !== ($file = readdir($dir))) { | |
| 100 |             if (($file !== '.') && ($file !== '..')) { | |
| @@ 127-129 (lines=3) @@ | ||
| 124 | */ | |
| 125 | public static function recurseCopyIfEdited($src = '', $dst = '', array $excludes = ['php']) | |
| 126 |     { | |
| 127 |         if (!is_dir($dst) && (!mkdir($dst) && !is_dir($dst))) { | |
| 128 |             throw new Exception('Copy dir error, access denied for path: '.$dst); | |
| 129 | } | |
| 130 | ||
| 131 | $dir = opendir($src); | |
| 132 |         if (!$dir) { | |
| @@ 42-44 (lines=3) @@ | ||
| 39 | ||
| 40 | $path = !empty($config['path']) ? $config['path'] : sys_get_temp_dir().'/cache'; | |
| 41 | ||
| 42 |         if (!@mkdir($path, 0600) && !is_dir($path)) { | |
| 43 |             throw new Exception('Can`not create/check access to directory: '.$path); | |
| 44 | } | |
| 45 | ||
| 46 | $this->driver = $path; | |
| 47 | } | |