Code Duplication    Length = 9-9 lines in 2 locations

src/Assert.php 2 locations

@@ 982-990 (lines=9) @@
979
        }
980
    }
981
982
    public static function keyExists($array, $key, $message = '')
983
    {
984
        if (!(isset($array[$key]) || array_key_exists($key, $array))) {
985
            static::reportInvalidArgument(sprintf(
986
                $message ?: 'Expected the key %s to exist.',
987
                static::valueToString($key)
988
            ));
989
        }
990
    }
991
992
    public static function keyNotExists($array, $key, $message = '')
993
    {
@@ 992-1000 (lines=9) @@
989
        }
990
    }
991
992
    public static function keyNotExists($array, $key, $message = '')
993
    {
994
        if (isset($array[$key]) || array_key_exists($key, $array)) {
995
            static::reportInvalidArgument(sprintf(
996
                $message ?: 'Expected the key %s to not exist.',
997
                static::valueToString($key)
998
            ));
999
        }
1000
    }
1001
1002
    public static function count($array, $number, $message = '')
1003
    {