Code Duplication    Length = 11-11 lines in 2 locations

src/Assert.php 2 locations

@@ 879-889 (lines=11) @@
876
        }
877
    }
878
879
    public static function file($value, $message = '')
880
    {
881
        static::fileExists($value, $message);
882
883
        if (!is_file($value)) {
884
            static::reportInvalidArgument(sprintf(
885
                $message ?: 'The path %s is not a file.',
886
                static::valueToString($value)
887
            ));
888
        }
889
    }
890
891
    public static function directory($value, $message = '')
892
    {
@@ 891-901 (lines=11) @@
888
        }
889
    }
890
891
    public static function directory($value, $message = '')
892
    {
893
        static::fileExists($value, $message);
894
895
        if (!is_dir($value)) {
896
            static::reportInvalidArgument(sprintf(
897
                $message ?: 'The path %s is no directory.',
898
                static::valueToString($value)
899
            ));
900
        }
901
    }
902
903
    public static function readable($value, $message = '')
904
    {