Update to drupal-org-drupal 8.0.0-rc2. For more information, see https://www.drupal.org/node/2598668
This commit is contained in:
parent
f32e58e4b1
commit
8e18df8c36
3062 changed files with 15044 additions and 172506 deletions
|
@ -33,11 +33,21 @@ abstract class SecuredRedirectResponse extends RedirectResponse {
|
|||
*/
|
||||
public static function createFromRedirectResponse(RedirectResponse $response) {
|
||||
$safe_response = new static($response->getTargetUrl(), $response->getStatusCode(), $response->headers->allPreserveCase());
|
||||
$safe_response->setProtocolVersion($response->getProtocolVersion());
|
||||
$safe_response->setCharset($response->getCharset());
|
||||
$safe_response->fromResponse($response);
|
||||
return $safe_response;
|
||||
}
|
||||
|
||||
/**
|
||||
* Copies over the values from the given response.
|
||||
*
|
||||
* @param \Symfony\Component\HttpFoundation\RedirectResponse $response
|
||||
* The redirect reponse object.
|
||||
*/
|
||||
protected function fromResponse(RedirectResponse $response) {
|
||||
$this->setProtocolVersion($response->getProtocolVersion());
|
||||
$this->setCharset($response->getCharset());
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
|
|
Reference in a new issue