MDL-43385 booktool_print: Remove unused $titles array
authorJun Pataleta <jun@moodle.com>
Tue, 5 Feb 2019 08:33:33 +0000 (16:33 +0800)
committerJun Pataleta <jun@moodle.com>
Tue, 5 Feb 2019 08:33:33 +0000 (16:33 +0800)
mod/book/tool/print/classes/output/renderer.php

index 21c2932..d94622d 100644 (file)
@@ -101,7 +101,6 @@ class renderer extends plugin_renderer_base {
     public function render_print_book_toc($chapters, $book, $cm) {
 
         $first = true;
-        $titles = array();
 
         $context = context_module::instance($cm->id);
 
@@ -150,7 +149,6 @@ class renderer extends plugin_renderer_base {
                     }
 
                 }
-                $titles[$ch->id] = $title;
 
                 if (!$ch->subchapter) {
                     $toc .= html_writer::link(new moodle_url('#ch' . $ch->id), $title,