Commit b8feed6e authored by totten's avatar totten

CRM-16373 - Config - Remove `userFrameworkVersion`

This is only very rarely used -- seems silly to look it up on every page
request and to cache it config object.
parent 94dbed1f
......@@ -304,8 +304,6 @@ class CRM_Core_Config extends CRM_Core_Config_Variables {
$this->cleanURL = 0;
}
$this->userFrameworkVersion = $this->userSystem->getVersion();
if ($userFramework == 'Joomla') {
/** @var object|null $mainframe */
global $mainframe;
......
......@@ -225,7 +225,6 @@ class CRM_Core_Config_Variables extends CRM_Core_Config_Defaults {
* Default user framework. This basically makes Drupal 7 the default
*/
public $userFramework = 'Drupal';
public $userFrameworkVersion = 'Unknown';
public $userFrameworkUsersTableName = 'users';
public $userFrameworkClass = 'CRM_Utils_System_Drupal';
public $userHookClass = 'CRM_Utils_Hook_Drupal';
......
......@@ -49,7 +49,7 @@ class CRM_Dedupe_Merger {
$title = ts('%1 User: %2; user id: %3', array(1 => $config->userFramework, 2 => '$ufname', 3 => '$ufid'));
}
elseif ($config->userFramework == 'Joomla') {
$userRecordUrl = $config->userFrameworkVersion > 1.5 ? $config->userFrameworkBaseURL . "index.php?option=com_users&view=user&task=user.edit&id=" . '%ufid' : $config->userFrameworkBaseURL . "index2.php?option=com_users&view=user&task=edit&id[]=" . '%ufid';
$userRecordUrl = $config->userSystem->getVersion() > 1.5 ? $config->userFrameworkBaseURL . "index.php?option=com_users&view=user&task=user.edit&id=" . '%ufid' : $config->userFrameworkBaseURL . "index2.php?option=com_users&view=user&task=edit&id[]=" . '%ufid';
$title = ts('%1 User: %2; user id: %3', array(1 => $config->userFramework, 2 => '$ufname', 3 => '$ufid'));
}
......
......@@ -288,7 +288,7 @@ class CRM_Utils_VersionCheck {
'uf' => $config->userFramework,
'lang' => $config->lcMessages,
'co' => $config->defaultContactCountry,
'ufv' => $config->userFrameworkVersion,
'ufv' => $config->userSystem->getVersion(),
'PHP' => phpversion(),
'MySQL' => CRM_CORE_DAO::singleValueQuery('SELECT VERSION()'),
'communityMessagesUrl' => Civi::settings()->get('communityMessagesUrl'),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment