mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
BUGFIX Supress mkdir() when attempting to create a temp folder, instead
of the variable. This gives a nicer error in the installer.
This commit is contained in:
parent
04e5ff09ca
commit
105986392b
@ -324,14 +324,14 @@ function getTempFolder($base = null) {
|
|||||||
$ssTmp = "$sysTmp/$cachefolder";
|
$ssTmp = "$sysTmp/$cachefolder";
|
||||||
|
|
||||||
if(!@file_exists($ssTmp)) {
|
if(!@file_exists($ssTmp)) {
|
||||||
@$worked = mkdir($ssTmp);
|
$worked = @mkdir($ssTmp);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!$worked) {
|
if(!$worked) {
|
||||||
$ssTmp = BASE_PATH . "/silverstripe-cache";
|
$ssTmp = BASE_PATH . "/silverstripe-cache";
|
||||||
$worked = true;
|
$worked = true;
|
||||||
if(!@file_exists($ssTmp)) {
|
if(!@file_exists($ssTmp)) {
|
||||||
@$worked = mkdir($ssTmp);
|
$worked = @mkdir($ssTmp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -725,14 +725,14 @@ class InstallRequirements {
|
|||||||
$ssTmp = "$sysTmp/silverstripe-cache";
|
$ssTmp = "$sysTmp/silverstripe-cache";
|
||||||
|
|
||||||
if(!@file_exists($ssTmp)) {
|
if(!@file_exists($ssTmp)) {
|
||||||
@$worked = mkdir($ssTmp);
|
$worked = @mkdir($ssTmp);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!$worked) {
|
if(!$worked) {
|
||||||
$ssTmp = dirname($_SERVER['SCRIPT_FILENAME']) . '/silverstripe-cache';
|
$ssTmp = dirname($_SERVER['SCRIPT_FILENAME']) . '/silverstripe-cache';
|
||||||
$worked = true;
|
$worked = true;
|
||||||
if(!@file_exists($ssTmp)) {
|
if(!@file_exists($ssTmp)) {
|
||||||
@$worked = mkdir($ssTmp);
|
$worked = @mkdir($ssTmp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user