Code Duplication    Length = 7-7 lines in 2 locations

src/voku/db/DB.php 2 locations

@@ 515-521 (lines=7) @@
512
  private function _parseQueryParams(string $sql, array $params = []): array
513
  {
514
    // is there anything to parse?
515
    if (
516
        \strpos($sql, '?') === false
517
        ||
518
        \count($params) === 0
519
    ) {
520
      return ['sql' => $sql, 'params' => $params];
521
    }
522
523
    $parseKey = \md5(\uniqid((string)\mt_rand(), true));
524
    $sql = \str_replace('?', $parseKey, $sql);
@@ 799-805 (lines=7) @@
796
  public function _parseQueryParamsByName(string $sql, array $params = []): array
797
  {
798
    // is there anything to parse?
799
    if (
800
        \strpos($sql, ':') === false
801
        ||
802
        \count($params) === 0
803
    ) {
804
      return ['sql' => $sql, 'params' => $params];
805
    }
806
807
    $parseKey = \md5(\uniqid((string)\mt_rand(), true));
808