Code Duplication    Length = 9-9 lines in 2 locations

src/Assert.php 2 locations

@@ 996-1004 (lines=9) @@
993
        }
994
    }
995
996
    public static function keyExists($array, $key, $message = '')
997
    {
998
        if (!(isset($array[$key]) || array_key_exists($key, $array))) {
999
            static::reportInvalidArgument(sprintf(
1000
                $message ?: 'Expected the key %s to exist.',
1001
                static::valueToString($key)
1002
            ));
1003
        }
1004
    }
1005
1006
    public static function keyNotExists($array, $key, $message = '')
1007
    {
@@ 1006-1014 (lines=9) @@
1003
        }
1004
    }
1005
1006
    public static function keyNotExists($array, $key, $message = '')
1007
    {
1008
        if (isset($array[$key]) || array_key_exists($key, $array)) {
1009
            static::reportInvalidArgument(sprintf(
1010
                $message ?: 'Expected the key %s to not exist.',
1011
                static::valueToString($key)
1012
            ));
1013
        }
1014
    }
1015
1016
    public static function count($array, $number, $message = '')
1017
    {