Simplification
This commit is contained in:
parent
5f38dcf1f9
commit
15cd1ca656
@ -91,34 +91,18 @@ if ($opts->install)
|
||||
$c = new Zend_Config($application->getOptions());
|
||||
|
||||
//Create data directory and all his children
|
||||
if ( !file_exists(APPLICATION_PATH.'/../data') )
|
||||
{
|
||||
mkdir(APPLICATION_PATH.'/../data');
|
||||
}
|
||||
|
||||
if ( !file_exists(APPLICATION_PATH.'/../data/cache') )
|
||||
{
|
||||
mkdir(APPLICATION_PATH.'/../data/cache');
|
||||
}
|
||||
|
||||
if ( !file_exists(APPLICATION_PATH.'/../data/cache') )
|
||||
{
|
||||
mkdir(APPLICATION_PATH.'/../data/log');
|
||||
}
|
||||
|
||||
if ( !file_exists(APPLICATION_PATH.'/../data/files') )
|
||||
{
|
||||
mkdir(APPLICATION_PATH.'/../data/files');
|
||||
}
|
||||
|
||||
if ( !file_exists(APPLICATION_PATH.'/../data/sessions') )
|
||||
{
|
||||
mkdir(APPLICATION_PATH.'/../data/sessions');
|
||||
}
|
||||
|
||||
if ( !file_exists(APPLICATION_PATH.'/../data/wdsl') )
|
||||
{
|
||||
mkdir(APPLICATION_PATH.'/../data/wsdl');
|
||||
$dirToCreate = array(
|
||||
APPLICATION_PATH.'/../data',
|
||||
APPLICATION_PATH.'/../data/cache',
|
||||
APPLICATION_PATH.'/../data/log',
|
||||
APPLICATION_PATH.'/../data/files',
|
||||
APPLICATION_PATH.'/../data/sessions',
|
||||
APPLICATION_PATH.'/../data/wsdl',
|
||||
);
|
||||
foreach ($dirToCreate as $dir) {
|
||||
if ( !file_exists($dir) ) {
|
||||
mkdir($dir);
|
||||
}
|
||||
}
|
||||
|
||||
// Generate cache file
|
||||
|
Loading…
Reference in New Issue
Block a user