From 082513badf1c6672bb5e871322235b4906b13f2d Mon Sep 17 00:00:00 2001 From: Petr Skoda Date: Sun, 6 May 2012 13:31:55 +0200 Subject: [PATCH] MDL-32807 remove PHP4 object reference coding style --- lib/navigationlib.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/navigationlib.php b/lib/navigationlib.php index f4b89df4288..83ef84b3629 100644 --- a/lib/navigationlib.php +++ b/lib/navigationlib.php @@ -758,9 +758,9 @@ class navigation_node_collection implements IteratorAggregate { } } // Add a reference to the node to the progressive collection. - $this->collection[$newindex] = &$this->orderedcollection[$type][$key]; + $this->collection[$newindex] = $this->orderedcollection[$type][$key]; // Update the last property to a reference to this new node. - $this->last = &$this->orderedcollection[$type][$key]; + $this->last = $this->orderedcollection[$type][$key]; // Reorder the array by index if needed if (!$last) { @@ -1632,7 +1632,7 @@ class global_navigation extends navigation_node { $categorynode->display = false; } } - $this->addedcategories[$category->id] = &$categorynode; + $this->addedcategories[$category->id] = $categorynode; } /** @@ -2322,7 +2322,7 @@ class global_navigation extends navigation_node { $coursenode->hidden = (!$course->visible); $coursenode->title(format_string($course->fullname, true, array('context' => get_context_instance(CONTEXT_COURSE, $course->id)))); if (!$forcegeneric) { - $this->addedcourses[$course->id] = &$coursenode; + $this->addedcourses[$course->id] = $coursenode; } if ($ismycourse && !empty($CFG->navshowallcourses)) { // We need to add this course to the general courses node as well as the @@ -4303,7 +4303,7 @@ class navigation_cache { if (!isset($SESSION->navcache->{$this->area})) { $SESSION->navcache->{$this->area} = array(); } - $this->session = &$SESSION->navcache->{$this->area}; + $this->session = &$SESSION->navcache->{$this->area}; // pointer to array, =& is correct here } }