Changeset View
Changeset View
Standalone View
Standalone View
src/applications/people/storage/PhabricatorUser.php
Show First 20 Lines • Show All 1,574 Lines • ▼ Show 20 Lines | /* -( User Cache )--------------------------------------------------------- */ | ||||
* @task cache | * @task cache | ||||
*/ | */ | ||||
public function clearCacheData($key) { | public function clearCacheData($key) { | ||||
unset($this->rawCacheData[$key]); | unset($this->rawCacheData[$key]); | ||||
unset($this->usableCacheData[$key]); | unset($this->usableCacheData[$key]); | ||||
return $this; | return $this; | ||||
} | } | ||||
public function getCSSValue($variable_key) { | |||||
$preference = PhabricatorAccessibilitySetting::SETTINGKEY; | |||||
$key = $this->getUserSetting($preference); | |||||
$postprocessor = CelerityPostprocessor::getPostprocessor($key); | |||||
$variables = $postprocessor->getVariables(); | |||||
if (!isset($variables[$variable_key])) { | |||||
throw new Exception( | |||||
pht( | |||||
'Unknown CSS variable "%s"!', | |||||
$variable_key)); | |||||
} | |||||
return $variables[$variable_key]; | |||||
} | |||||
} | } |