mirror of
https://github.com/danog/dns.git
synced 2024-11-30 04:29:06 +01:00
Merge branch 'v0.9.x'
This commit is contained in:
commit
b023ecda84
@ -84,7 +84,7 @@ function isValidName(string $name)
|
||||
*/
|
||||
function normalizeName(string $name): string
|
||||
{
|
||||
static $pattern = '/^(?<name>[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)(\.(?&name))*$/i';
|
||||
static $pattern = '/^(?<name>[a-z0-9]([a-z0-9-_]{0,61}[a-z0-9])?)(\.(?&name))*$/i';
|
||||
|
||||
if (\function_exists('idn_to_ascii') && \defined('INTL_IDNA_VARIANT_UTS46')) {
|
||||
if (false === $result = \idn_to_ascii($name, 0, \INTL_IDNA_VARIANT_UTS46)) {
|
||||
|
Loading…
Reference in New Issue
Block a user