mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-30 21:47:30 +00:00
make getConfigDir static
This commit is contained in:
parent
8cf4901a46
commit
bfd02591c8
|
@ -872,7 +872,7 @@ class Settings { /* {{{ */
|
|||
function searchConfigFilePath() { /* {{{ */
|
||||
$configFilePath = null;
|
||||
|
||||
if($configDir = $this->getConfigDir()) {
|
||||
if($configDir = Settings::getConfigDir()) {
|
||||
if (file_exists($configDir."/settings.xml"))
|
||||
return $configDir."/settings.xml";
|
||||
}
|
||||
|
@ -888,7 +888,7 @@ class Settings { /* {{{ */
|
|||
* 3. The directory /etc/seeddms
|
||||
* @return NULL|string config directory
|
||||
*/
|
||||
function getConfigDir() { /* {{{ */
|
||||
static function getConfigDir() { /* {{{ */
|
||||
$_tmp = dirname($_SERVER['SCRIPT_FILENAME']);
|
||||
$_arr = preg_split('/\//', rtrim(str_replace('\\', '/', $_tmp)));
|
||||
$configDir = null;
|
||||
|
|
Loading…
Reference in New Issue
Block a user