src/Message.php
public function withAddedHeader($name, $value)
    {
        if (isset($this->_headers[$name]))
        {
            // 如果是数组，那么合并
            if (is_array($value))
            {
                $this->_headers[$name] = Arr::merge($this->_headers[$name], $value);
            }
            // 否则直接新增
            else
            {
                $this->_headers[$name][] = $value;
            }
        }
        else
        {
            $this->withHeader($name, $value);
        }

        return $this;
    }
public function withAddedHeader($name, $value)
    {
        if (isset($this->_headers[$name]))
        {
            // 如果是数组，那么合并
            if (is_array($value))
            {
                $this->_headers[$name] = Arr::merge($this->_headers[$name], $value);
            }
            // 否则直接新增
            else
            {
                $this->_headers[$name][] = $value;
            }
        }
        else
        {
            $this->withHeader($name, $value);
        }

        return $this;
    }
{@inheritdoc}