replace deprecated session->appsession with Api\Cache::(s|g)etSession()

This commit is contained in:
Ralf Becker 2016-10-12 17:52:30 +02:00
parent 9b4d727eb0
commit ae7211af6d
2 changed files with 3 additions and 3 deletions

View File

@ -202,7 +202,7 @@ class notifications_ajax {
* @return boolean true
*/
private function restore_session_data() {
$session_data = $GLOBALS['egw']->session->appsession('session_data',self::_appname);
$session_data = Api\Cache::getSession(self::_appname, 'session_data');
if(is_array($session_data)) {
$this->session_data = $session_data;
} else {
@ -218,7 +218,7 @@ class notifications_ajax {
* @return boolean true
*/
private function save_session_data() {
$GLOBALS['egw']->session->appsession('session_data',self::_appname,$this->session_data);
Api\Cache::setSession(self::_appname, 'session_data', $this->session_data);
return true;
}
}

View File

@ -284,7 +284,7 @@ class resources_ui
if ($use_all)
{
// get the whole selection
$query = is_array($session_name) ? $session_name : $GLOBALS['egw']->session->appsession('session_data', $session_name);
$query = is_array($session_name) ? $session_name : Api\Cache::getSession($session_name, 'session_data');
@set_time_limit(0); // switch off the execution time limit, as it's for big selections to small
$query['num_rows'] = -1; // all