Changeset View
Changeset View
Standalone View
Standalone View
src/view/page/PhabricatorStandardPageView.php
Show First 20 Lines • Show All 162 Lines • ▼ Show 20 Lines | Javelin::initBehavior( | ||||
array( | array( | ||||
'tokenName' => AphrontRequest::getCSRFTokenName(), | 'tokenName' => AphrontRequest::getCSRFTokenName(), | ||||
'header' => AphrontRequest::getCSRFHeaderName(), | 'header' => AphrontRequest::getCSRFHeaderName(), | ||||
'current' => $current_token, | 'current' => $current_token, | ||||
)); | )); | ||||
Javelin::initBehavior('device'); | Javelin::initBehavior('device'); | ||||
if ($user->hasSession()) { | |||||
$hisec = ($user->getSession()->getHighSecurityUntil() - time()); | |||||
if ($hisec > 0) { | |||||
$remaining_time = phabricator_format_relative_time($hisec); | |||||
Javelin::initBehavior( | |||||
'high-security-warning', | |||||
array( | |||||
'uri' => '/auth/session/downgrade/', | |||||
'message' => pht( | |||||
'Your session is in high security mode. When you '. | |||||
'finish using it, click here to leave.', | |||||
$remaining_time), | |||||
)); | |||||
} | |||||
} | |||||
if ($console) { | if ($console) { | ||||
require_celerity_resource('aphront-dark-console-css'); | require_celerity_resource('aphront-dark-console-css'); | ||||
$headers = array(); | $headers = array(); | ||||
if (DarkConsoleXHProfPluginAPI::isProfilerStarted()) { | if (DarkConsoleXHProfPluginAPI::isProfilerStarted()) { | ||||
$headers[DarkConsoleXHProfPluginAPI::getProfilerHeader()] = 'page'; | $headers[DarkConsoleXHProfPluginAPI::getProfilerHeader()] = 'page'; | ||||
} | } | ||||
if (DarkConsoleServicesPlugin::isQueryAnalyzerRequested()) { | if (DarkConsoleServicesPlugin::isQueryAnalyzerRequested()) { | ||||
▲ Show 20 Lines • Show All 249 Lines • Show Last 20 Lines |