src/VCR/RequestMatcher.php
public static function matchHeaders(Request $first, Request $second)
    {
        // Use array_filter to ignore headers which are null.

        return array_filter($first->getHeaders()) === array_filter($second->getHeaders());
    }
public static function matchHeaders(Request $first, Request $second)
    {
        // Use array_filter to ignore headers which are null.

        return array_filter($first->getHeaders()) === array_filter($second->getHeaders());
    }
public static function matchHeaders ( Request $ first , Request $ second ) { // Use array_filter to ignore headers which are null. return array_filter ( $ first -> getHeaders ( ) ) === array_filter ( $ second -> getHeaders ( ) ) ; }
Returns true if the headers of both specified requests match.

@param  Request $first  First request to match.
@param  Request $second Second request to match.

@return boolean True if the headers of both specified requests match.
Returns true if the headers of both specified requests match .