Code Duplication    Length = 3-3 lines in 2 locations

admin/entry.php 1 location

@@ 402-404 (lines=3) @@
399
    // Save to database
400
    if (!$entryID) {
401
        // verify that the term does not exists
402
        if (LexikonUtility::isTermPresent($term, $xoopsDB->prefix('lxentries'))) {
403
            redirect_header('javascript:history.go(-1)', 2, _AM_LEXIKON_ITEMEXISTS . '<br>' . $term);
404
        }
405
        if ($xoopsDB->query('INSERT INTO '
406
                            . $xoopsDB->prefix('lxentries')
407
                            . " (entryID, categoryID, term, init, definition, ref, url, uid, submit, datesub, html, smiley, xcodes, breaks, block, offline, notifypub, request ) VALUES (0, '$categoryID', '$term', '$init', '$definition', '$ref', '$url', '$uid', '$submit', '$date', '$html', '$smiley', '$xcodes', '$breaks', '$block', '$offline', '$notifypub', '$request' )")

submit.php 1 location

@@ 141-143 (lines=3) @@
138
            $autoapprove = 1;
139
        }
140
        // verify that the term not exists
141
        if (LexikonUtility::isTermPresent($term, $xoopsDB->prefix('lxentries'))) {
142
            redirect_header('javascript:history.go(-1)', 2, _MD_LEXIKON_ITEMEXISTS . '<br>' . $term);
143
        }
144
        $result = $xoopsDB->query('INSERT INTO '
145
                                  . $xoopsDB->prefix('lxentries')
146
                                  . " (entryID, categoryID, term, init, definition, ref, url, uid, submit, datesub, html, smiley, xcodes, breaks, block, offline, notifypub ) VALUES ('', '$categoryID', '$term', '$init', '$definition', '$ref', '$url', '$uid', '$submit', '$datesub', '$html', '$smiley', '$xcodes', '$breaks','$block', '$offline', '$notifypub')");