mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-27 02:14:45 +01:00
clean up of cache after using (admin) connection via forceEAProfileLoad
This commit is contained in:
parent
ea69e2c99b
commit
e72881e484
@ -1221,6 +1221,7 @@
|
||||
'email' => html::input('account_email',$group_repository['account_email'],'',' style="width: 100%;"'),
|
||||
));
|
||||
}
|
||||
emailadmin_bo::unsetCachedObjects($default_profile_id);
|
||||
}
|
||||
}
|
||||
$availableApps = $GLOBALS['egw_info']['apps'];
|
||||
|
@ -167,6 +167,12 @@ class felamimail_bo
|
||||
*/
|
||||
public static function getInstance($_restoreSession=true, $_profileID=0, $_validate=true)
|
||||
{
|
||||
if ($_profileID == 0)
|
||||
{
|
||||
$profileID = emailadmin_bo::getDefaultProfileID();
|
||||
if ($profileID!=$_profileID) $_restoreSession==false;
|
||||
$_profileID=$profileID;
|
||||
}
|
||||
if ($_profileID != 0 && $_validate)
|
||||
{
|
||||
$profileID = self::validateProfileID($_restoreSession, $_profileID);
|
||||
@ -182,7 +188,7 @@ class felamimail_bo
|
||||
}
|
||||
}
|
||||
//error_log(__METHOD__.__LINE__.' RestoreSession:'.$_restoreSession.' ProfileId:'.$_profileID.' called from:'.function_backtrace());
|
||||
if (!isset(self::$instances[$_profileID]))
|
||||
if (!isset(self::$instances[$_profileID]) || $_restoreSession===false)
|
||||
{
|
||||
self::$instances[$_profileID] = new felamimail_bo('utf-8',$_restoreSession,$_profileID);
|
||||
}
|
||||
@ -412,7 +418,7 @@ class felamimail_bo
|
||||
* @param int $_profile_id must be a value lower than 0 (emailadmin profile)
|
||||
* @return object instance of felamimail_bo (by reference)
|
||||
*/
|
||||
public static function &forceEAProfileLoad($_profile_id)
|
||||
public static function forceEAProfileLoad($_profile_id)
|
||||
{
|
||||
$bofelamimail = felamimail_bo::getInstance(false, $_profile_id,false);
|
||||
//_debug_array( $_profile_id);
|
||||
|
@ -36,6 +36,7 @@ class felamimail_hooks
|
||||
$bofelamimail->updateAccount($hookData);
|
||||
break;
|
||||
}
|
||||
emailadmin_bo::unsetCachedObjects($default_profile_id);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user