Code Duplication    Length = 9-9 lines in 2 locations

src/voku/helper/UTF8.php 2 locations

@@ 5078-5086 (lines=9) @@
5075
      self::checkForSupport();
5076
    }
5077
5078
    if (
5079
        $encoding !== 'UTF-8'
5080
        &&
5081
        self::$SUPPORT['mbstring'] === false
5082
        &&
5083
        self::$SUPPORT['iconv'] === false
5084
    ) {
5085
      trigger_error('UTF8::strlen() without mbstring / iconv cannot handle "' . $encoding . '" encoding', E_USER_WARNING);
5086
    }
5087
5088
    if (
5089
        $encoding !== 'UTF-8'
@@ 5287-5295 (lines=9) @@
5284
      self::checkForSupport();
5285
    }
5286
5287
    if (
5288
        $encoding !== 'UTF-8'
5289
        &
5290
        self::$SUPPORT['iconv'] === true
5291
        &&
5292
        self::$SUPPORT['mbstring'] === false
5293
    ) {
5294
      trigger_error('UTF8::strpos() without mbstring / iconv cannot handle "' . $encoding . '" encoding', E_USER_WARNING);
5295
    }
5296
5297
    if (
5298
        $offset >= 0 // iconv_strpos() can't handle negative offset