restore file in the root folder if the origin folder is not writable
This commit is contained in:
parent
6ab95e8e33
commit
dbb0d04073
1 changed files with 3 additions and 1 deletions
|
@ -91,7 +91,9 @@ class Trashbin {
|
|||
|
||||
// if location no longer exists, restore file in the root directory
|
||||
$location = $result[0]['location'];
|
||||
if ( $result[0]['location'] != '/' && !$view->is_dir('files'.$result[0]['location']) ) {
|
||||
if ( $result[0]['location'] != '/' &&
|
||||
(!$view->is_dir('files'.$result[0]['location']) ||
|
||||
!$view->is_writable('files'.$result[0]['location'])) ) {
|
||||
$location = '';
|
||||
}
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue