Code Duplication    Length = 6-6 lines in 2 locations

src/voku/db/DB.php 2 locations

@@ 1502-1507 (lines=6) @@
1499
    if ($query_result === true) {
1500
1501
      // "INSERT" || "REPLACE"
1502
      if (preg_match('/^\s*?(?:INSERT|REPLACE)\s+/i', $sql)) {
1503
        $insert_id = (int)$this->insert_id();
1504
        $this->_debug->logQuery($sql, $query_duration, $insert_id);
1505
1506
        return $insert_id;
1507
      }
1508
1509
      // "UPDATE" || "DELETE"
1510
      if (preg_match('/^\s*?(?:UPDATE|DELETE)\s+/i', $sql)) {
@@ 1510-1515 (lines=6) @@
1507
      }
1508
1509
      // "UPDATE" || "DELETE"
1510
      if (preg_match('/^\s*?(?:UPDATE|DELETE)\s+/i', $sql)) {
1511
        $affected_rows = $this->affected_rows();
1512
        $this->_debug->logQuery($sql, $query_duration, $affected_rows);
1513
1514
        return $affected_rows;
1515
      }
1516
1517
      // log the ? query
1518
      $this->_debug->logQuery($sql, $query_duration, 0);