function RESTTestBase::drupalGetHeader

Overrides WebTestBase::drupalGetHeader

File

core/modules/rest/src/Tests/RESTTestBase.php, line 273

Class

RESTTestBase
Test helper class that provides a REST client method to send HTTP requests.

Namespace

Drupal\rest\Tests

Code

protected function drupalGetHeader($name, $all_requests = FALSE) {
    if (!isset($this->response)) {
        return parent::drupalGetHeader($name, $all_requests);
    }
    if ($header = $this->response
        ->getHeader($name)) {
        return implode(', ', $header);
    }
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.