From: systopia Date: Mon, 20 Jul 2015 14:02:58 +0000 (+0200) Subject: proposed changes for CRM-16871 X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=4dd6dceb4beb91d980ccaaaccb0a59d1ac6a56c8;p=civicrm-core.git proposed changes for CRM-16871 --- diff --git a/api/v3/Job.php b/api/v3/Job.php index c6a27618e4..9c8dc356de 100644 --- a/api/v3/Job.php +++ b/api/v3/Job.php @@ -568,6 +568,8 @@ function civicrm_api3_job_cleanup($params) { $prevNext = CRM_Utils_Array::value('prevNext', $params, TRUE); $dbCache = CRM_Utils_Array::value('dbCache', $params, FALSE); $memCache = CRM_Utils_Array::value('memCache', $params, FALSE); + $tplCache = CRM_Utils_Array::value('tplCache' , $params, FALSE ); + $wordRplc = CRM_Utils_Array::value('wordRplc' , $params, FALSE ); if ($session || $tempTable || $prevNext) { CRM_Core_BAO_Cache::cleanup($session, $tempTable, $prevNext); @@ -577,6 +579,11 @@ function civicrm_api3_job_cleanup($params) { CRM_Core_BAO_Job::cleanup(); } + if ( $tplCache ) { + $config = CRM_Core_Config::singleton(); + $config->cleanup(1, FALSE); + } + if ($dbCache) { CRM_Core_Config::clearDBCache(); } @@ -584,6 +591,10 @@ function civicrm_api3_job_cleanup($params) { if ($memCache) { CRM_Utils_System::flushCache(); } + + if ( $wordRplc ) { + CRM_Core_BAO_WordReplacement::rebuild(); + } } /**