Code Duplication    Length = 6-6 lines in 2 locations

src/voku/db/DB.php 2 locations

@@ 1481-1486 (lines=6) @@
1478
    if ($query_result === true) {
1479
1480
      // "INSERT" || "REPLACE"
1481
      if (preg_match('/^\s*?(?:INSERT|REPLACE)\s+/i', $sql)) {
1482
        $insert_id = (int)$this->insert_id();
1483
        $this->_debug->logQuery($sql, $query_duration, $insert_id);
1484
1485
        return $insert_id;
1486
      }
1487
1488
      // "UPDATE" || "DELETE"
1489
      if (preg_match('/^\s*?(?:UPDATE|DELETE)\s+/i', $sql)) {
@@ 1489-1494 (lines=6) @@
1486
      }
1487
1488
      // "UPDATE" || "DELETE"
1489
      if (preg_match('/^\s*?(?:UPDATE|DELETE)\s+/i', $sql)) {
1490
        $affected_rows = (int)$this->affected_rows();
1491
        $this->_debug->logQuery($sql, $query_duration, $affected_rows);
1492
1493
        return $affected_rows;
1494
      }
1495
1496
      // log the ? query
1497
      $this->_debug->logQuery($sql, $query_duration, 0);