Fix #3001: the current code needs an array, not an object

This commit is contained in:
Raphaël Doursenaud 2015-06-10 18:45:10 +02:00
parent 7f06727c56
commit 2629e47f77

View File

@ -215,7 +215,7 @@ if ($action == 'add')
$object->duree=((float) (GETPOST('dureehour') * 60) + (float) GETPOST('dureemin')) * 60;
$listofuserid=array();
if (! empty($_SESSION['assignedtouser'])) $listofuserid=json_decode($_SESSION['assignedtouser']);
if (! empty($_SESSION['assignedtouser'])) $listofuserid=json_decode($_SESSION['assignedtouser'], true);
$i=0;
foreach($listofuserid as $key => $value)
{