From 1df12a701d8e9d6dffc692c12c5036969a9d2d82 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20Doursenaud?= Date: Tue, 7 Aug 2012 14:10:16 +0200 Subject: [PATCH] Fix: Display correct user in project tasks' time spent list Use a local object rather than modifying the global $user object (sic!) --- htdocs/projet/tasks/time.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/htdocs/projet/tasks/time.php b/htdocs/projet/tasks/time.php index 2e0d8b66984..b3738abc8d0 100644 --- a/htdocs/projet/tasks/time.php +++ b/htdocs/projet/tasks/time.php @@ -403,17 +403,17 @@ if ($id > 0 || ! empty($ref)) print ''; // User - $user->id = $task_time->fk_user; + $userstatic = new User($task_time->fk_user); print ''; if ($_GET['action'] == 'editline' && $_GET['lineid'] == $task_time->rowid) { - print $form->select_users($user->id,'userid_line'); + print $form->select_users($userstatic->id,'userid_line'); } else { - $user->nom = $task_time->name; - $user->prenom = $task_time->firstname; - print $user->getNomUrl(1); + $userstatic->nom = $task_time->name; + $userstatic->prenom = $task_time->firstname; + print $userstatic->getNomUrl(1); } print '';