Code Duplication    Length = 6-6 lines in 2 locations

src/voku/db/DB.php 2 locations

@@ 1604-1609 (lines=6) @@
1601
    if ($query_result === true) {
1602
1603
      // "INSERT" || "REPLACE"
1604
      if (preg_match('/^\s*?(?:INSERT|REPLACE)\s+/i', $sql)) {
1605
        $insert_id = (int)$this->insert_id();
1606
        $this->_debug->logQuery($sql, $query_duration, $insert_id);
1607
1608
        return $insert_id;
1609
      }
1610
1611
      // "UPDATE" || "DELETE"
1612
      if (preg_match('/^\s*?(?:UPDATE|DELETE)\s+/i', $sql)) {
@@ 1612-1617 (lines=6) @@
1609
      }
1610
1611
      // "UPDATE" || "DELETE"
1612
      if (preg_match('/^\s*?(?:UPDATE|DELETE)\s+/i', $sql)) {
1613
        $affected_rows = $this->affected_rows();
1614
        $this->_debug->logQuery($sql, $query_duration, $affected_rows);
1615
1616
        return $affected_rows;
1617
      }
1618
1619
      // log the ? query
1620
      $this->_debug->logQuery($sql, $query_duration, 0);