Code Duplication    Length = 9-9 lines in 2 locations

src/Assert.php 2 locations

@@ 1801-1809 (lines=9) @@
1798
     *
1799
     * @throws InvalidArgumentException
1800
     */
1801
    public static function methodExists($classOrObject, $method, $message = '')
1802
    {
1803
        if (!\method_exists($classOrObject, $method)) {
1804
            static::reportInvalidArgument(\sprintf(
1805
                $message ?: 'Expected the method %s to exist.',
1806
                static::valueToString($method)
1807
            ));
1808
        }
1809
    }
1810
1811
    /**
1812
     * @psalm-pure
@@ 1821-1829 (lines=9) @@
1818
     *
1819
     * @throws InvalidArgumentException
1820
     */
1821
    public static function methodNotExists($classOrObject, $method, $message = '')
1822
    {
1823
        if (\method_exists($classOrObject, $method)) {
1824
            static::reportInvalidArgument(\sprintf(
1825
                $message ?: 'Expected the method %s to not exist.',
1826
                static::valueToString($method)
1827
            ));
1828
        }
1829
    }
1830
1831
    /**
1832
     * @psalm-pure