$value) { $output .= $key . ': ' . (is_array($value) ? implode(', ', $value) : $value) . "\r\n"; } return $output . "\r\n"; } public function send(): void { if (headers_sent()) { return; } foreach ($this as $key => $value) { header($key . ': ' . (is_array($value) ? implode(', ', $value) : $value)); } } }