only in patch2: unchanged: --- a/core/includes/common.inc +++ b/core/includes/common.inc @@ -668,8 +668,6 @@ function _url($path = NULL, array $options = array()) { * @return * A ; separated string ready for insertion in a HTTP header. No escaping is * performed for HTML entities, so this string is not safe to be printed. - * - * @see drupal_add_http_header() */ function drupal_http_header_attributes(array $attributes = array()) { foreach ($attributes as $attribute => &$data) { only in patch2: unchanged: --- a/core/modules/system/tests/modules/system_test/system_test.module +++ b/core/modules/system/tests/modules/system_test/system_test.module @@ -2,6 +2,7 @@ use Drupal\Core\Extension\Extension; use Symfony\Component\HttpFoundation\RedirectResponse; +use Symfony\Component\HttpFoundation\Response; /** * Sets a header. @@ -10,7 +11,8 @@ */ function system_test_set_header() { $query = \Drupal::request()->query->all(); - drupal_add_http_header($query['name'], $query['value']); + $response = new Response(); + $response->headers->set($query['name'], $query['value']); return t('The following header was set: %name: %value', array('%name' => $query['name'], '%value' => $query['value'])); }