Code Duplication    Length = 20-20 lines in 2 locations

src/voku/helper/UTF8.php 2 locations

@@ 3429-3448 (lines=20) @@
3426
      $useExceptions = false;
3427
    }
3428
3429
    foreach ($words as $word) {
3430
3431
      if (!$word) {
3432
        continue;
3433
      }
3434
3435
      if (
3436
          $useExceptions === false
3437
          ||
3438
          (
3439
              $useExceptions === true
3440
              &&
3441
              !in_array($word, $exceptions, true)
3442
          )
3443
      ) {
3444
        $word = self::lcfirst($word, $encoding, $cleanUtf8);
3445
      }
3446
3447
      $newWords[] = $word;
3448
    }
3449
3450
    return implode('', $newWords);
3451
  }
@@ 7468-7487 (lines=20) @@
7465
      $useExceptions = false;
7466
    }
7467
7468
    foreach ($words as $word) {
7469
7470
      if (!$word) {
7471
        continue;
7472
      }
7473
7474
      if (
7475
          $useExceptions === false
7476
          ||
7477
          (
7478
              $useExceptions === true
7479
              &&
7480
              !in_array($word, $exceptions, true)
7481
          )
7482
      ) {
7483
        $word = self::ucfirst($word, $encoding);
7484
      }
7485
7486
      $newWords[] = $word;
7487
    }
7488
7489
    return implode('', $newWords);
7490
  }