protected function withHeaders(array $headers)
    {
        $clean = [];

        foreach ($headers as $key => $value) {
            if (! Str::startsWith($key, ['HTTP_', 'CONTENT_'])) {
                $key = 'HTTP_' . $key;
            }

            $clean[$key] = $value;
        }

        $this->headers = array_merge($this->headers, $clean);

        return $this;
    }
protected function withHeaders(array $headers)
    {
        $clean = [];

        foreach ($headers as $key => $value) {
            if (! Str::startsWith($key, ['HTTP_', 'CONTENT_'])) {
                $key = 'HTTP_' . $key;
            }

            $clean[$key] = $value;
        }

        $this->headers = array_merge($this->headers, $clean);

        return $this;
    }
protected function withHeaders ( array $ headers ) { $ clean = [ ] ; foreach ( $ headers as $ key => $ value ) { if ( ! Str :: startsWith ( $ key , [ 'HTTP_' , 'CONTENT_' ] ) ) { $ key = 'HTTP_' . $ key ; } $ clean [ $ key ] = $ value ; } $ this -> headers = array_merge ( $ this -> headers , $ clean ) ; return $ this ; }
An array of headers to pass along with the request

@param array $headers
@return $this
An array of headers to pass along with the request