mirror of
				https://git.code.sf.net/p/seeddms/code
				synced 2025-10-31 13:18:06 +00:00 
			
		
		
		
	fix recursive removal and copying of dirs
This commit is contained in:
		
							parent
							
								
									790eef7e84
								
							
						
					
					
						commit
						1a61a6ca8f
					
				|  | @ -205,14 +205,14 @@ class SeedDMS_Core_File { | |||
| 		{ | ||||
| 			if ($entry == ".." || $entry == ".") | ||||
| 				continue; | ||||
| 			else if (is_dir($path . $entry)) | ||||
| 			else if (is_dir($path . DIRECTORY_SEPARATOR . $entry)) | ||||
| 			{ | ||||
| 				if (!self::removeDir($path . $entry . "/")) | ||||
| 				if (!self::removeDir($path . DIRECTORY_SEPARATOR . $entry . "/")) | ||||
| 					return false; | ||||
| 			} | ||||
| 			else | ||||
| 			{ | ||||
| 				if (!@unlink($path . $entry)) | ||||
| 				if (!@unlink($path . DIRECTORY_SEPARATOR . $entry)) | ||||
| 					return false; | ||||
| 			} | ||||
| 		} | ||||
|  | @ -232,10 +232,10 @@ class SeedDMS_Core_File { | |||
| 				if ($entry == ".." || $entry == ".") | ||||
| 					continue; | ||||
| 				else if (is_dir($sourcePath . $entry)) { | ||||
| 					if (!self::copyDir($sourcePath . $entry . "/", $targetPath . $entry . "/")) | ||||
| 					if (!self::copyDir($sourcePath . DIRECTORY_SEPARATOR . $entry, $targetPath . DIRECTORY_SEPARATOR . $entry)) | ||||
| 						return false; | ||||
| 				} else { | ||||
| 					if (!@copy($sourcePath . $entry, $targetPath . $entry)) | ||||
| 					if (!@copy($sourcePath . DIRECTORY_SEPARATOR . $entry, $targetPath . DIRECTORY_SEPARATOR . $entry)) | ||||
| 						return false; | ||||
| 				} | ||||
| 			} | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Uwe Steinmann
						Uwe Steinmann