Permission should be really fixed now
This commit is contained in:
parent
6dcfd35d31
commit
52c85408af
@ -121,24 +121,6 @@ class Configuration {
|
|||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function checkPermissions() {
|
|
||||||
$classes = array(
|
|
||||||
\Configuration\Database::class,
|
|
||||||
\Configuration\Mail::class,
|
|
||||||
\Configuration\JWT::class
|
|
||||||
);
|
|
||||||
|
|
||||||
$files = array();
|
|
||||||
foreach($classes as $class) {
|
|
||||||
$file = getClassPath($class);
|
|
||||||
if(!is_writeable($file)) {
|
|
||||||
$files[] = $file;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return $files;
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
@ -130,13 +130,11 @@ namespace Documents\Install {
|
|||||||
$success = true;
|
$success = true;
|
||||||
$failedRequirements = array();
|
$failedRequirements = array();
|
||||||
|
|
||||||
$unwriteableFiles = \Configuration\Configuration::checkPermissions();
|
$configDir = "core/Configuration/";
|
||||||
if(!empty($unwriteableFiles)) {
|
if(!is_writeable($configDir)) {
|
||||||
foreach($unwriteableFiles as $file) {
|
$failedRequirements[] = "<b>$configDir</b> is not writeable. Try running <b>chmod 755</b>";
|
||||||
$failedRequirements[] = "<b>$file</b> is not writeable. Try running <b>chmod 600</b>";
|
|
||||||
$success = false;
|
$success = false;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if(version_compare(PHP_VERSION, '7.1', '<')) {
|
if(version_compare(PHP_VERSION, '7.1', '<')) {
|
||||||
$failedRequirements[] = "PHP Version <b>>= 7.1</b> is required. Got: <b>" . PHP_VERSION . "</b>";
|
$failedRequirements[] = "PHP Version <b>>= 7.1</b> is required. Got: <b>" . PHP_VERSION . "</b>";
|
||||||
|
Loading…
Reference in New Issue
Block a user