mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-17 15:03:25 +00:00
Update Session controller
This commit is contained in:
@@ -41,7 +41,7 @@ class Session implements ControllerProviderInterface
|
||||
*
|
||||
* return : JSON Response
|
||||
*/
|
||||
$controllers->get('/update/', $this->call('updateSession'))
|
||||
$controllers->post('/update/', $this->call('updateSession'))
|
||||
->bind('update_session');
|
||||
|
||||
return $controllers;
|
||||
@@ -56,6 +56,10 @@ class Session implements ControllerProviderInterface
|
||||
*/
|
||||
public function updateSession(Application $app, Request $request)
|
||||
{
|
||||
if(!$request->isXmlHttpRequest()) {
|
||||
$app->abort(400);
|
||||
}
|
||||
|
||||
$ret = array(
|
||||
'status' => 'unknown',
|
||||
'message' => '',
|
||||
|
Reference in New Issue
Block a user