mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-17 23:13:15 +00:00
Logout in case the session is not found
This commit is contained in:
@@ -11,6 +11,8 @@
|
||||
|
||||
use Alchemy\Phrasea\Application;
|
||||
|
||||
use Alchemy\Phrasea\Exception\SessionNotFound;
|
||||
|
||||
/**
|
||||
*
|
||||
* @package User
|
||||
@@ -1461,6 +1463,10 @@ class User_Adapter implements User_Interface, cache_cacheableInterface
|
||||
|
||||
$session = $app['EM']->find('Entities\Session', $app['session']->get('session_id'));
|
||||
|
||||
if (!$session) {
|
||||
throw new SessionNotFound('No session found');
|
||||
}
|
||||
|
||||
if (!$session->hasModuleId($app_id)) {
|
||||
$module = new \Entities\SessionModule();
|
||||
|
||||
|
Reference in New Issue
Block a user