Skip to content

Commit

Permalink
let's try to do this more logically
Browse files Browse the repository at this point in the history
  • Loading branch information
Radek-Suski committed Mar 3, 2016
1 parent 1085f72 commit 2b394ef
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions administrator/components/com_admin/models/sysinfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,14 @@ protected function cleanPrivateData($dataArray, $dataType = 'other')

if (in_array($section, $privateSettings, true))
{
$dataArray[$section] = $this->cleanSectionPrivateData($values);
if( strstr($values, JPATH_ROOT))
{
$dataArray[$section] = 'xxxxxx';
}
else
{
$dataArray[$section] = $this->cleanSectionPrivateData($values);
}
}
}

Expand Down Expand Up @@ -598,8 +605,8 @@ public function getDirectory()
$this->addDirectory('administrator/cache', JPATH_CACHE, 'COM_ADMIN_CACHE_DIRECTORY');
}

$this->addDirectory($registry->get('log_path', JPATH_ROOT . '/log'), $registry->get('log_path', JPATH_ROOT . '/log'), 'COM_ADMIN_LOG_DIRECTORY');
$this->addDirectory($registry->get('tmp_path', JPATH_ROOT . '/tmp'), $registry->get('tmp_path', JPATH_ROOT . '/tmp'), 'COM_ADMIN_TEMP_DIRECTORY');
$this->addDirectory('log', $registry->get('log_path', JPATH_ROOT . '/log'), 'COM_ADMIN_LOG_DIRECTORY');
$this->addDirectory('tmp', $registry->get('tmp_path', JPATH_ROOT . '/tmp'), 'COM_ADMIN_TEMP_DIRECTORY');

return $this->directories;
}
Expand All @@ -617,7 +624,7 @@ public function getDirectory()
*/
private function addDirectory($name, $path, $message = '')
{
$this->directories[str_replace(JPATH_ROOT, '', $name)] = array('writable' => is_writable($path), 'message' => $message);
$this->directories[$name] = array('writable' => is_writable($path), 'message' => $message);
}

/**
Expand Down

0 comments on commit 2b394ef

Please sign in to comment.