Code Duplication    Length = 9-9 lines in 3 locations

src/Assert.php 3 locations

@@ 472-480 (lines=9) @@
469
        }
470
    }
471
472
    public static function ip($value, $message = '')
473
    {
474
        if (false === filter_var($value, FILTER_VALIDATE_IP)) {
475
            static::reportInvalidArgument(sprintf(
476
                $message ?: 'Expected a value to be an IP. Got: %s',
477
                static::valueToString($value)
478
            ));
479
        }
480
    }
481
482
    public static function ipv4($value, $message = '')
483
    {
@@ 482-490 (lines=9) @@
479
        }
480
    }
481
482
    public static function ipv4($value, $message = '')
483
    {
484
        if (false === filter_var($value, FILTER_VALIDATE_IP, FILTER_FLAG_IPV4)) {
485
            static::reportInvalidArgument(sprintf(
486
                $message ?: 'Expected a value to be an IPv4. Got: %s',
487
                static::valueToString($value)
488
            ));
489
        }
490
    }
491
492
    public static function ipv6($value, $message = '')
493
    {
@@ 492-500 (lines=9) @@
489
        }
490
    }
491
492
    public static function ipv6($value, $message = '')
493
    {
494
        if (false === filter_var($value, FILTER_VALIDATE_IP, FILTER_FLAG_IPV6)) {
495
            static::reportInvalidArgument(sprintf(
496
                $message ?: 'Expected a value to be an IPv6. Got %s',
497
                static::valueToString($value)
498
            ));
499
        }
500
    }
501
502
    public static function uniqueValues(array $values, $message = '')
503
    {