Code Duplication    Length = 9-9 lines in 2 locations

src/voku/helper/UTF8.php 2 locations

@@ 5377-5385 (lines=9) @@
5374
      $str = self::clean($str);
5375
    }
5376
5377
    if (
5378
        $encoding !== 'UTF-8'
5379
        &&
5380
        self::$SUPPORT['mbstring'] === false
5381
        &&
5382
        self::$SUPPORT['iconv'] === false
5383
    ) {
5384
      trigger_error('UTF8::strlen() without mbstring / iconv cannot handle "' . $encoding . '" encoding', E_USER_WARNING);
5385
    }
5386
5387
    if (
5388
        $encoding !== 'UTF-8'
@@ 5594-5602 (lines=9) @@
5591
      return strpos($haystack, $needle, $offset);
5592
    }
5593
5594
    if (
5595
        $encoding !== 'UTF-8'
5596
        &
5597
        self::$SUPPORT['iconv'] === true
5598
        &&
5599
        self::$SUPPORT['mbstring'] === false
5600
    ) {
5601
      trigger_error('UTF8::strpos() without mbstring / iconv cannot handle "' . $encoding . '" encoding', E_USER_WARNING);
5602
    }
5603
5604
    if (
5605
        $offset >= 0 // iconv_strpos() can't handle negative offset