src/SnooPHP/Http/Response.php
public function header_old($name = null, $value = null)
	{
		// Set
		if ($value !== null)
		{
			if (is_array($value))
				foreach ($value as $field => $val) $this->headers[$field] = $val;
			else if (is_string($name))
				$this->headers[$name] = $value;
		}

		// Get
		return !$name ? $this->headers : ($this->headers[$name] ?? null);
	}
public function header_old($name = null, $value = null)
	{
		// Set
		if ($value !== null)
		{
			if (is_array($value))
				foreach ($value as $field => $val) $this->headers[$field] = $val;
			else if (is_string($name))
				$this->headers[$name] = $value;
		}

		// Get
		return !$name ? $this->headers : ($this->headers[$name] ?? null);
	}
Get or set header

@deprecated v0.2.5

If both parameters are null all headers are returned
otherwise the header identified by $name field is returned
and if $value is not null the field value is updated

@param string|array	$name	field name
@param string|array	$value	header value or array of field => value to set

@return string|array