Skip to content

Commit

Permalink
Uri::getUsername is an alias for Uri::getUser
Browse files Browse the repository at this point in the history
  • Loading branch information
nyamsprod committed Jan 5, 2025
1 parent 5139a62 commit 58ccecf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Idna/Converter.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
use function idn_to_ascii;
use function idn_to_utf8;
use function rawurldecode;
use function strtolower;

use const INTL_IDNA_VARIANT_UTS46;

Expand Down Expand Up @@ -155,7 +156,7 @@ public static function toUnicode(Stringable|string $domain, Option|int|null $opt
idn_to_utf8($domain, $flags->toBytes(), INTL_IDNA_VARIANT_UTS46, $idnaInfo);

if ([] === $idnaInfo) {
return Result::fromIntl(['result' => $domain, 'isTransitionalDifferent' => false, 'errors' => Error::NONE->value]);
return Result::fromIntl(['result' => strtolower($domain), 'isTransitionalDifferent' => false, 'errors' => Error::NONE->value]);
}

return Result::fromIntl($idnaInfo);
Expand Down

0 comments on commit 58ccecf

Please sign in to comment.