src/Message.php
public function hasHeader($name)
    {
        $name = mb_convert_case($name, MB_CASE_TITLE);

        return isset($this->headers[$name]);
    }
public function hasHeader($name)
    {
        $name = mb_convert_case($name, MB_CASE_TITLE);

        return isset($this->headers[$name]);
    }
Checks if a header exists by the given case-insensitive name.

@param string $name Case-insensitive header field name.

@return bool Returns true if any header names match the given header
name using a case-insensitive string comparison. Returns false if
no matching header name is found in the message.