Code Duplication    Length = 9-9 lines in 3 locations

src/Assert.php 3 locations

@@ 457-465 (lines=9) @@
454
        }
455
    }
456
457
    public static function ip($value, $message = '')
458
    {
459
        if (false === filter_var($value, FILTER_VALIDATE_IP)) {
460
            static::reportInvalidArgument(sprintf(
461
                $message ?: 'Expected a value to be an IP. Got: %s',
462
                static::valueToString($value)
463
            ));
464
        }
465
    }
466
467
    public static function ipv4($value, $message = '')
468
    {
@@ 467-475 (lines=9) @@
464
        }
465
    }
466
467
    public static function ipv4($value, $message = '')
468
    {
469
        if (false === filter_var($value, FILTER_VALIDATE_IP, FILTER_FLAG_IPV4)) {
470
            static::reportInvalidArgument(sprintf(
471
                $message ?: 'Expected a value to be an IPv4. Got: %s',
472
                static::valueToString($value)
473
            ));
474
        }
475
    }
476
477
    public static function ipv6($value, $message = '')
478
    {
@@ 477-485 (lines=9) @@
474
        }
475
    }
476
477
    public static function ipv6($value, $message = '')
478
    {
479
        if (false === filter_var($value, FILTER_VALIDATE_IP, FILTER_FLAG_IPV6)) {
480
            static::reportInvalidArgument(sprintf(
481
                $message ?: 'Expected a value to be an IPv6. Got %s',
482
                static::valueToString($value)
483
            ));
484
        }
485
    }
486
487
    public static function eq($value, $value2, $message = '')
488
    {