Code Duplication    Length = 4-4 lines in 2 locations

main/newscorm/learnpath.class.php 2 locations

@@ 7551-7554 (lines=4) @@
7548
            $item_title = stripslashes($extra_info['title']);
7549
            $item_description = stripslashes($extra_info['description']);
7550
            $item_terms = stripslashes($extra_info['terms']);
7551
            if (empty ($item_title)) {
7552
                $path_parts = pathinfo($extra_info['path']);
7553
                $item_title = stripslashes($path_parts['filename']);
7554
            }
7555
        } elseif (is_numeric($extra_info)) {
7556
            $sql_doc = "SELECT path, title FROM " . $tbl_doc . "
7557
                        WHERE
@@ 7565-7568 (lines=4) @@
7562
            $row 	= Database::fetch_array($result);
7563
            $item_title = $row['title'];
7564
            $item_title = str_replace('_', ' ', $item_title);
7565
            if (empty ($item_title)) {
7566
                $path_parts = pathinfo($row['path']);
7567
                $item_title = stripslashes($path_parts['filename']);
7568
            }
7569
        } else {
7570
            $item_title = '';
7571
            $item_description = '';