Allow a custom data path to be set directly in include.php.

This commit is contained in:
Techwolf 2017-01-04 19:01:26 -08:00
parent df29eb85cd
commit 0dcbac8820
2 changed files with 1 additions and 2 deletions

View file

@ -33,7 +33,6 @@ mv data $DIR/var/lib/rainloop;
#Update settings for Debian package
sed -i "s/\$sCustomDataPath = '';/\$sCustomDataPath = '\/var\/lib\/rainloop';/" $DIR/usr/share/rainloop/rainloop/v/$VERSION/include.php
sed -i "s/\$sCustomDataPath = \(.*\) : '';/\$sCustomDataPath = \1 : \$sCustomDataPath;/" $DIR/usr/share/rainloop/rainloop/v/$VERSION/include.php
#Set up Debian packaging tools
cd $DIR;

View file

@ -55,7 +55,7 @@
include_once APP_INDEX_ROOT_PATH.'include.php';
}
$sCustomDataPath = function_exists('__get_custom_data_full_path') ? rtrim(trim(__get_custom_data_full_path()), '\\/') : '';
$sCustomDataPath = function_exists('__get_custom_data_full_path') ? rtrim(trim(__get_custom_data_full_path()), '\\/') : $sCustomDataPath;
define('APP_DATA_FOLDER_PATH', 0 === strlen($sCustomDataPath) ? APP_INDEX_ROOT_PATH.'data/' : $sCustomDataPath.'/');
unset($sCustomDataPath);