Code Duplication    Length = 4-4 lines in 2 locations

main/newscorm/learnpath.class.php 2 locations

@@ 7560-7563 (lines=4) @@
7557
            $item_title = stripslashes($extra_info['title']);
7558
            $item_description = stripslashes($extra_info['description']);
7559
            $item_terms = stripslashes($extra_info['terms']);
7560
            if (empty ($item_title)) {
7561
                $path_parts = pathinfo($extra_info['path']);
7562
                $item_title = stripslashes($path_parts['filename']);
7563
            }
7564
        } elseif (is_numeric($extra_info)) {
7565
            $sql_doc = "SELECT path, title FROM " . $tbl_doc . "
7566
                        WHERE
@@ 7574-7577 (lines=4) @@
7571
            $row 	= Database::fetch_array($result);
7572
            $item_title = $row['title'];
7573
            $item_title = str_replace('_', ' ', $item_title);
7574
            if (empty ($item_title)) {
7575
                $path_parts = pathinfo($row['path']);
7576
                $item_title = stripslashes($path_parts['filename']);
7577
            }
7578
        } else {
7579
            $item_title = '';
7580
            $item_description = '';