From af91b6813fb6f81be1cef16dc98ff9f73d210c70 Mon Sep 17 00:00:00 2001 From: Uwe Steinmann Date: Tue, 20 Oct 2015 18:36:24 +0200 Subject: [PATCH] do not use reference to array item, use index --- views/bootstrap/class.ViewDocument.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/views/bootstrap/class.ViewDocument.php b/views/bootstrap/class.ViewDocument.php index 0ad2e5857..62936d17a 100644 --- a/views/bootstrap/class.ViewDocument.php +++ b/views/bootstrap/class.ViewDocument.php @@ -80,7 +80,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style { if($user->isAdmin()) { $data = $document->getTimeline(); - foreach($data as &$item) { + foreach($data as $i=>$item) { switch($item['type']) { case 'add_version': $msg = getMLText('timeline_'.$item['type'], array('document'=>htmlspecialchars($item['document']->getName()), 'version'=> $item['version'])); @@ -94,7 +94,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style { default: $msg = '???'; } - $item['msg'] = $msg; + $data[$i]['msg'] = $msg; } foreach($data as $item) {