Code Duplication    Length = 9-9 lines in 3 locations

src/Assert.php 3 locations

@@ 521-529 (lines=9) @@
518
        }
519
    }
520
521
    public static function ip($value, $message = '')
522
    {
523
        if (false === filter_var($value, FILTER_VALIDATE_IP)) {
524
            static::reportInvalidArgument(sprintf(
525
                $message ?: 'Expected a value to be an IP. Got: %s',
526
                static::valueToString($value)
527
            ));
528
        }
529
    }
530
531
    public static function ipv4($value, $message = '')
532
    {
@@ 531-539 (lines=9) @@
528
        }
529
    }
530
531
    public static function ipv4($value, $message = '')
532
    {
533
        if (false === filter_var($value, FILTER_VALIDATE_IP, FILTER_FLAG_IPV4)) {
534
            static::reportInvalidArgument(sprintf(
535
                $message ?: 'Expected a value to be an IPv4. Got: %s',
536
                static::valueToString($value)
537
            ));
538
        }
539
    }
540
541
    public static function ipv6($value, $message = '')
542
    {
@@ 541-549 (lines=9) @@
538
        }
539
    }
540
541
    public static function ipv6($value, $message = '')
542
    {
543
        if (false === filter_var($value, FILTER_VALIDATE_IP, FILTER_FLAG_IPV6)) {
544
            static::reportInvalidArgument(sprintf(
545
                $message ?: 'Expected a value to be an IPv6. Got %s',
546
                static::valueToString($value)
547
            ));
548
        }
549
    }
550
551
    public static function uniqueValues(array $values, $message = '')
552
    {