fixing mkdir code to respect external file systems as well
This commit is contained in:
parent
d15a4719d2
commit
7dd0074655
|
@ -633,11 +633,11 @@ class View {
|
||||||
if (Filesystem::isValidPath($path)) {
|
if (Filesystem::isValidPath($path)) {
|
||||||
|
|
||||||
// Get directory that the file is going into
|
// Get directory that the file is going into
|
||||||
$file_path = \OC_User::getHome(\OC_User::getUser()) . '/files'.substr($path, 0, strrpos($path,'/'));
|
$filePath = dirname($path);
|
||||||
|
|
||||||
// Create the directories if any
|
// Create the directories if any
|
||||||
if(empty($file_path) === false) {
|
if (!$this->file_exists($filePath)) {
|
||||||
mkdir($file_path, 0770, true);
|
$this->mkdir($filePath);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$tmpFile) {
|
if (!$tmpFile) {
|
||||||
|
|
Loading…
Reference in New Issue