- do not try to create files in conten directory if it could not be

found in the first place
This commit is contained in:
steinm 2012-01-17 08:31:45 +00:00
parent 797cc442fd
commit c196697420

View File

@ -762,20 +762,20 @@ class Settings { /* {{{ */
$errorMsgPerms = null;
// perms
if (!mkdir($this->_contentDir.'/_CHECK_TEST_')) {
if (!@mkdir($this->_contentDir.'/_CHECK_TEST_')) {
$errorMsgPerms .= "Create folder - ";
}
} else {
if (is_bool(file_put_contents($this->_contentDir.'/_CHECK_TEST_/_CHECK_TEST_', ""))) {
$errorMsgPerms .= "Create file - ";
} else {
if (!unlink ($this->_contentDir.'/_CHECK_TEST_/_CHECK_TEST_')) {
$errorMsgPerms .= "Delete file - ";
}
}
if (is_bool(file_put_contents($this->_contentDir.'/_CHECK_TEST_/_CHECK_TEST_', ""))) {
$errorMsgPerms .= "Create file - ";
}
if (!unlink ($this->_contentDir.'/_CHECK_TEST_/_CHECK_TEST_')) {
$errorMsgPerms .= "Delete file - ";
}
if (!rmdir($this->_contentDir.'/_CHECK_TEST_')) {
$errorMsgPerms .= "Delete folder";
if (!rmdir($this->_contentDir.'/_CHECK_TEST_')) {
$errorMsgPerms .= "Delete folder";
}
}
if (!is_null($errorMsgPerms)) {