Code Duplication    Length = 14-14 lines in 2 locations

class/dbupdater.php 1 location

@@ 439-452 (lines=14) @@
436
     * @return bool true if success, false if an error occured
437
     *
438
     */
439
    public function runQuery($query, $goodmsg, $badmsg)
440
    {
441
        global $xoopsDB;
442
        $ret = $xoopsDB->query($query);
443
        if (!$ret) {
444
            echo "<li class='err'>$badmsg</li>";
445
446
            return false;
447
        } else {
448
            echo "<li class='ok'>$goodmsg</li>";
449
450
            return true;
451
        }
452
    }
453
454
    /**
455
     * Use to rename a table

class/smartdbupdater.php 1 location

@@ 586-599 (lines=14) @@
583
     * @return bool true if success, false if an error occured
584
     *
585
     */
586
    public function runQuery($query, $goodmsg, $badmsg)
587
    {
588
        global $xoopsDB;
589
        $ret = $xoopsDB->query($query);
590
        if (!$ret) {
591
            echo "&nbsp;&nbsp;$badmsg<br>";
592
593
            return false;
594
        } else {
595
            echo "&nbsp;&nbsp;$goodmsg<br>";
596
597
            return true;
598
        }
599
    }
600
601
    /**
602
     * Use to rename a table